/**
 * Custom CSS for Tectuary Theme
 * Additional styles and overrides
 */

/* ==========================================================================
   Additional Hero Styles
   ========================================================================== */

.hero-section {
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(130,0,159,0.1) 0%, transparent 70%);
    animation: rotate 30s linear infinite;
}

@keyframes rotate {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Animation Classes */
.animate-fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.animate-fade-in.animated {
    opacity: 1;
    transform: translateY(0);
}

.animate-fade-in-delay {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out 0.2s;
}

.animate-fade-in-delay.animated {
    opacity: 1;
    transform: translateY(0);
}

.animate-fade-in-delay-2 {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out 0.4s;
}

.animate-fade-in-delay-2.animated {
    opacity: 1;
    transform: translateY(0);
}

.animate-fade-in-delay-3 {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out 0.6s;
}

.animate-fade-in-delay-3.animated {
    opacity: 1;
    transform: translateY(0);
}

/* ==========================================================================
   Service Cards
   ========================================================================== */

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.service-card {
    text-align: center;
    padding: 2.5rem 2rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--tectuary-gradient-primary);
    opacity: 0;
    transition: opacity 0.3s ease;
    z-index: -1;
}

.service-card.hover::before,
.service-card:hover::before {
    opacity: 0.05;
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    background: var(--tectuary-gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.service-icon .dashicons {
    width: 60px;
    height: 60px;
    font-size: 60px;
}

/* ==========================================================================
   About Section
   ========================================================================== */

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-text h2 {
    margin-bottom: 1.5rem;
}

.image-placeholder {
    position: relative;
    height: 400px;
    border-radius: 15px;
    overflow: hidden;
}

.gradient-box {
    width: 100%;
    height: 100%;
    background: var(--tectuary-gradient-primary);
    opacity: 0.8;
    animation: gradientShift 8s ease infinite;
}

@keyframes gradientShift {
    0%, 100% {
        transform: scale(1) rotate(0deg);
    }
    50% {
        transform: scale(1.1) rotate(5deg);
    }
}

/* ==========================================================================
   Features Grid
   ========================================================================== */

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature {
    padding: 2rem;
    background: var(--tectuary-gray-100);
    border-radius: 10px;
    transition: all 0.3s ease;
}

.feature:hover {
    background: var(--tectuary-light);
    box-shadow: var(--tectuary-shadow-lg);
    transform: translateY(-5px);
}

.feature h3 {
    margin-bottom: 1rem;
    color: var(--tectuary-gray-900);
}

/* ==========================================================================
   Posts Grid
   ========================================================================== */

.posts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.post-card {
    overflow: hidden;
    transition: all 0.3s ease;
}

.post-card:hover {
    transform: translateY(-10px);
}

.post-thumbnail {
    height: 200px;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.post-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.post-card:hover .post-thumbnail img {
    transform: scale(1.1);
}

.post-content h3 {
    margin-bottom: 1rem;
}

.post-content h3 a {
    color: var(--tectuary-gray-900);
    text-decoration: none;
    transition: color 0.3s ease;
}

.post-content h3 a:hover {
    color: var(--tectuary-primary);
}

.post-meta {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: var(--tectuary-gray-600);
}

.read-more {
    display: inline-block;
    color: var(--tectuary-primary);
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
}

.read-more:hover {
    color: var(--tectuary-secondary);
    transform: translateX(5px);
}

/* ==========================================================================
   CTA Section
   ========================================================================== */

.cta-section {
    background: var(--tectuary-gradient-dark);
    position: relative;
    overflow: hidden;
}

.cta-content {
    text-align: center;
    padding: 5rem 2rem;
    position: relative;
    z-index: 2;
}

.cta-content h2 {
    color: var(--tectuary-light);
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 1.5rem;
}

.cta-content p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.25rem;
    margin-bottom: 2.5rem;
}

.btn-large {
    padding: 1.25rem 3rem;
    font-size: 1.1rem;
}

/* ==========================================================================
   Back to Top Button
   ========================================================================== */

.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--tectuary-gradient-primary);
    border: none;
    border-radius: 50%;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    display: none;
    z-index: 999;
    transition: all 0.3s ease;
    box-shadow: var(--tectuary-shadow-lg);
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(247,52,94,0.4);
}

/* ==========================================================================
   Archive Pages
   ========================================================================== */

.archive-posts {
    display: grid;
    gap: 2rem;
}

.archive-post-card {
    background: var(--tectuary-light);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: var(--tectuary-shadow-md);
    transition: all 0.3s ease;
}

.archive-post-card:hover {
    box-shadow: var(--tectuary-shadow-xl);
    transform: translateY(-5px);
}

.archive-post-wrapper {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 2rem;
}

.archive-post-thumbnail {
    height: 200px;
    overflow: hidden;
}

.archive-post-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.archive-post-card:hover .archive-post-thumbnail img {
    transform: scale(1.1);
}

.archive-post-content {
    padding: 2rem;
}

/* ==========================================================================
   Single Post
   ========================================================================== */

.single-post-article {
    background: var(--tectuary-light);
    border-radius: 15px;
    padding: 3rem;
    margin-bottom: 3rem;
    box-shadow: var(--tectuary-shadow-md);
}

.author-bio {
    display: flex;
    gap: 2rem;
    margin-top: 3rem;
    padding-top: 3rem;
    border-top: 1px solid var(--tectuary-gray-200);
}

.author-avatar img {
    border-radius: 50%;
}

.author-name {
    margin-bottom: 1rem;
}

.author-link {
    color: var(--tectuary-primary);
    font-weight: 600;
    text-decoration: none;
}

.author-link:hover {
    color: var(--tectuary-secondary);
}

/* ==========================================================================
   404 Page
   ========================================================================== */

.error-404 {
    text-align: center;
    padding: 5rem 0;
}

.error-title {
    font-size: clamp(5rem, 10vw, 10rem);
    margin-bottom: 2rem;
}

.error-code {
    background: var(--tectuary-gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.error-message {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    color: var(--tectuary-gray-800);
}

.error-actions {
    margin: 3rem 0;
}

.error-widgets {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 4rem;
    text-align: left;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 1024px) {
    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .archive-post-wrapper {
        grid-template-columns: 1fr;
    }

    .archive-post-thumbnail {
        height: 250px;
    }
}

@media (max-width: 768px) {
    .services-grid,
    .features-grid,
    .posts-grid {
        grid-template-columns: 1fr;
    }

    .single-post-article {
        padding: 1.5rem;
    }

    .author-bio {
        flex-direction: column;
        text-align: center;
    }

    .error-widgets {
        grid-template-columns: 1fr;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
}

@media (max-width: 480px) {
    .hero-buttons {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }

    .btn {
        width: 100%;
    }

    .error-title {
        font-size: 4rem;
    }

    .error-message {
        font-size: 1.5rem;
    }
}

/* ==========================================================================
   Blog Columns Section
   ========================================================================== */

.blog-section {
    background: var(--tectuary-gray-100);
}

.blog-columns {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.blog-column {
    padding: 2rem;
}

.column-title {
    margin-bottom: 1.5rem;
    color: var(--tectuary-gray-900);
    font-size: 1.5rem;
    border-bottom: 2px solid var(--tectuary-primary);
    padding-bottom: 0.5rem;
}

.mini-post {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--tectuary-gray-200);
}

.mini-post:last-child {
    border-bottom: none;
}

.mini-post-thumb {
    width: 80px;
    height: 60px;
    flex-shrink: 0;
    border-radius: 8px;
    overflow: hidden;
    background: var(--tectuary-gray-200);
}

.mini-post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gradient-thumb {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.gradient-thumb-2 {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.gradient-thumb-3 {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.mini-post-content h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1rem;
    line-height: 1.4;
}

.mini-post-content h4 a {
    color: var(--tectuary-gray-900);
    text-decoration: none;
}

.mini-post-content h4 a:hover {
    color: var(--tectuary-primary);
}

.post-category {
    font-size: 0.85rem;
    color: var(--tectuary-gray-600);
}

/* Newsletter Column */
.newsletter-column {
    background: var(--tectuary-gradient-primary);
    color: var(--tectuary-light);
}

.newsletter-column .column-title {
    color: var(--tectuary-light);
    border-bottom-color: rgba(255, 255, 255, 0.3);
}

.newsletter-icon {
    font-size: 3rem;
    text-align: center;
    margin: 1rem 0;
    opacity: 0.9;
}

.newsletter-form {
    margin-top: 1.5rem;
}

.newsletter-form input[type="email"] {
    width: 100%;
    padding: 0.75rem;
    margin-bottom: 1rem;
    border: none;
    border-radius: 25px;
    font-size: 1rem;
}

.newsletter-form .btn {
    width: 100%;
}

/* ==========================================================================
   Testimonials Section
   ========================================================================== */

.testimonials-section {
    background: var(--tectuary-light);
    position: relative;
    overflow: hidden;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.testimonial {
    padding: 2rem;
    text-align: center;
    position: relative;
}

.testimonial::before {
    content: '"';
    position: absolute;
    top: 10px;
    left: 20px;
    font-size: 4rem;
    color: var(--tectuary-primary);
    opacity: 0.2;
}

.testimonial-stars {
    color: #ffd700;
    font-size: 1.25rem;
    margin-bottom: 1rem;
}

.testimonial-text {
    font-style: italic;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    color: var(--tectuary-gray-700);
}

.testimonial-author {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.testimonial-author strong {
    color: var(--tectuary-gray-900);
    font-size: 1.1rem;
}

.testimonial-author span {
    color: var(--tectuary-gray-600);
    font-size: 0.9rem;
}

/* ==========================================================================
   Pricing Section
   ========================================================================== */

.pricing-section {
    background: var(--tectuary-gray-100);
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
    align-items: stretch;
}

.pricing-card {
    padding: 2.5rem 2rem;
    text-align: center;
    position: relative;
    display: flex;
    flex-direction: column;
    background: var(--tectuary-light);
}

.pricing-card.featured {
    transform: scale(1.05);
    box-shadow: var(--tectuary-shadow-xl);
    border: 2px solid var(--tectuary-primary);
}

.pricing-badge {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--tectuary-gradient-primary);
    color: var(--tectuary-light);
    padding: 0.5rem 1.5rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.pricing-header {
    margin-bottom: 2rem;
}

.pricing-header h3 {
    margin-bottom: 1.5rem;
    color: var(--tectuary-gray-900);
}

.pricing-price {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 0.25rem;
}

.pricing-price .currency {
    font-size: 1.5rem;
    color: var(--tectuary-gray-600);
}

.pricing-price .amount {
    font-size: 3rem;
    font-weight: 700;
    background: var(--tectuary-gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.pricing-price .period {
    font-size: 1rem;
    color: var(--tectuary-gray-600);
}

.pricing-features {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem 0;
    flex-grow: 1;
}

.pricing-features li {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--tectuary-gray-200);
}

.pricing-features li:last-child {
    border-bottom: none;
}

.pricing-card .btn {
    margin-top: auto;
}

/* ==========================================================================
   Section Headers
   ========================================================================== */

.section-header {
    margin-bottom: 3rem;
}

.section-subtitle {
    display: inline-block;
    color: var(--tectuary-secondary);
    font-size: 1.1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.5rem;
}

.section-title {
    font-size: clamp(2rem, 4vw, 3rem);
    margin-bottom: 1rem;
}

.section-description {
    font-size: 1.25rem;
    color: var(--tectuary-gray-600);
}

/* ==========================================================================
   Feature Icons Update
   ========================================================================== */

.feature-icon {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--tectuary-gradient-primary);
    border-radius: 50%;
    margin: 0 auto 1.5rem;
}

.feature-icon .dashicons {
    color: var(--tectuary-light);
    width: 40px;
    height: 40px;
    font-size: 40px;
}

/* ==========================================================================
   CTA Images
   ========================================================================== */

.final-cta {
    position: relative;
    background: var(--tectuary-gradient-dark);
    overflow: hidden;
}

.cta-title {
    font-size: clamp(2.5rem, 5vw, 4rem);
}

.cta-subtitle {
    font-size: 1.5rem;
    color: var(--tectuary-secondary);
    margin-bottom: 1rem;
}

.cta-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

.cta-images {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.cta-image-left {
    position: absolute;
    top: -20%;
    left: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(130,0,159,0.3) 0%, transparent 70%);
    animation: float 6s ease-in-out infinite;
}

.cta-image-right {
    position: absolute;
    bottom: -20%;
    right: -10%;
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(247,52,94,0.3) 0%, transparent 70%);
    animation: float 6s ease-in-out infinite reverse;
}

/* Responsive adjustments for new sections */
@media (max-width: 768px) {
    .blog-columns,
    .testimonials-grid,
    .pricing-grid {
        grid-template-columns: 1fr;
    }

    .pricing-card.featured {
        transform: scale(1);
    }

    .cta-buttons {
        flex-direction: column;
        width: 100%;
    }

    .cta-buttons .btn {
        width: 100%;
    }
}