/*
Theme Name: Vinayam Legal
Theme URI: https://vinayamlegal.com
Author: Vinayam Legal
Description: A modern, professional legal portfolio theme with custom animations and responsive design.
Version: 1.0
License: GNU General Public License v2 or later
Text Domain: vinayam-legal
*/

/* ===== RESET & BASE ===== */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #1B2A4A;
    --primary-light: #2A3F6B;
    --accent: #C9A96E;
    --accent-hover: #B8944F;
    --dark: #0D1117;
    --light: #F8F9FA;
    --text: #2D3436;
    --text-light: #636E72;
    --white: #FFFFFF;
    --shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Inter', sans-serif;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-body);
    color: var(--text);
    line-height: 1.7;
    overflow-x: hidden;
    background: var(--white);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--primary);
    line-height: 1.3;
}

h1 { font-size: clamp(2.5rem, 5vw, 4rem); }
h2 { font-size: clamp(2rem, 4vw, 3rem); }
h3 { font-size: clamp(1.3rem, 2.5vw, 1.8rem); }

p {
    margin-bottom: 1rem;
    color: var(--text-light);
}

/* ===== SECTION STYLES ===== */
.section {
    padding: 100px 0;
    position: relative;
}

.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

.section-header h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background: var(--accent);
}

.section-header p {
    max-width: 600px;
    margin: 20px auto 0;
    font-size: 1.1rem;
}

/* ===== HEADER & NAVIGATION ===== */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 20px 0;
    transition: var(--transition);
    background: transparent;
}

.site-header.scrolled {
    background: var(--white);
    padding: 12px 0;
    box-shadow: var(--shadow);
}

.site-header.scrolled .nav-link {
    color: var(--primary);
}

.site-header.scrolled .nav-logo {
    color: var(--primary);
}

.nav-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.nav-logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--white);
    transition: var(--transition);
}

.nav-logo span {
    color: var(--accent);
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 35px;
}

.nav-link {
    color: var(--white);
    font-weight: 500;
    font-size: 0.95rem;
    position: relative;
    padding: 5px 0;
    transition: var(--transition);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--accent);
    transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
    width: 100%;
}

.nav-link:hover {
    color: var(--accent);
}

.nav-cta {
    background: var(--accent);
    color: var(--white) !important;
    padding: 10px 25px;
    border-radius: 4px;
    font-weight: 600;
}

.nav-cta::after {
    display: none;
}

.nav-cta:hover {
    background: var(--accent-hover);
    transform: translateY(-2px);
}

/* Mobile menu toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 5px;
}

.nav-toggle span {
    width: 25px;
    height: 2px;
    background: var(--white);
    transition: var(--transition);
}

.site-header.scrolled .nav-toggle span {
    background: var(--primary);
}

/* ===== HERO SECTION ===== */
.hero {
    position: relative;
    height: 100vh;
    min-height: 700px;
    display: flex;
    align-items: center;
    overflow: hidden;
}

.hero-carousel {
    position: absolute;
    inset: 0;
    z-index: 1;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 1.2s ease-in-out;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.hero-slide.active {
    opacity: 1;
}

.hero-slide::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(13, 17, 23, 0.85) 0%, rgba(27, 42, 74, 0.7) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 700px;
    padding: 0 20px;
}

.hero-content .container {
    padding: 0;
}

.hero-subtitle {
    font-family: var(--font-body);
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 4px;
    color: var(--accent);
    margin-bottom: 20px;
    font-weight: 500;
}

.hero-title {
    color: var(--white);
    margin-bottom: 25px;
    font-weight: 700;
}

.hero-description {
    color: rgba(255, 255, 255, 0.8);
    font-size: 1.15rem;
    margin-bottom: 35px;
    max-width: 550px;
}

.hero-buttons {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition);
    cursor: pointer;
    border: none;
}

.btn-primary {
    background: var(--accent);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--accent-hover);
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(201, 169, 110, 0.3);
}

.btn-outline {
    background: transparent;
    color: var(--white);
    border: 2px solid rgba(255, 255, 255, 0.4);
}

.btn-outline:hover {
    border-color: var(--accent);
    color: var(--accent);
    transform: translateY(-3px);
}

/* Carousel indicators */
.hero-indicators {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    gap: 10px;
}

.hero-indicator {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: var(--transition);
}

.hero-indicator.active {
    background: var(--accent);
    transform: scale(1.2);
}

/* ===== ABOUT SECTION ===== */
.about {
    background: var(--white);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: center;
}

.about-image {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
}

.about-image img {
    width: 100%;
    height: 450px;
    object-fit: cover;
    border-radius: 8px;
}

.about-image::before {
    content: '';
    position: absolute;
    top: -20px;
    left: -20px;
    width: 100%;
    height: 100%;
    border: 3px solid var(--accent);
    border-radius: 8px;
    z-index: -1;
}

.about-content h2 {
    margin-bottom: 20px;
}

.about-content p {
    margin-bottom: 15px;
    font-size: 1.05rem;
}

.about-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-top: 30px;
    padding-top: 30px;
    border-top: 1px solid #eee;
}

.stat-item {
    text-align: center;
}

.stat-number {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    color: var(--accent);
    font-weight: 700;
    line-height: 1;
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-light);
    margin-top: 5px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* ===== SERVICES SECTION ===== */
.services {
    background: var(--light);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card {
    background: var(--white);
    padding: 40px 30px;
    border-radius: 8px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--accent);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

.service-card:hover::before {
    transform: scaleX(1);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.service-icon {
    width: 60px;
    height: 60px;
    background: rgba(201, 169, 110, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    font-size: 1.8rem;
}

.service-card h3 {
    margin-bottom: 12px;
    font-size: 1.3rem;
}

.service-card p {
    font-size: 0.95rem;
    line-height: 1.7;
}

.service-card .learn-more {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-top: 15px;
    color: var(--accent);
    font-weight: 600;
    font-size: 0.9rem;
}

.service-card .learn-more:hover {
    gap: 10px;
}

/* ===== CLIENTS SECTION ===== */
.clients {
    background: var(--white);
}

.clients-logos {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 40px;
    align-items: center;
    margin-bottom: 60px;
}

.client-logo {
    background: var(--light);
    padding: 30px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100px;
    transition: var(--transition);
    filter: grayscale(100%);
    opacity: 0.6;
}

.client-logo:hover {
    filter: grayscale(0%);
    opacity: 1;
    box-shadow: var(--shadow);
    transform: scale(1.05);
}

.client-logo img {
    max-height: 50px;
    width: auto;
}

/* Testimonials */
.testimonials-wrapper {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    overflow: hidden;
}

.testimonial-card {
    background: var(--light);
    padding: 40px;
    border-radius: 8px;
    text-align: center;
    position: relative;
}

.testimonial-card::before {
    content: '\201C';
    font-family: var(--font-heading);
    font-size: 5rem;
    color: var(--accent);
    opacity: 0.3;
    position: absolute;
    top: 10px;
    left: 30px;
    line-height: 1;
}

.testimonial-text {
    font-size: 1.1rem;
    font-style: italic;
    color: var(--text);
    margin-bottom: 20px;
    line-height: 1.8;
}

.testimonial-author {
    font-weight: 600;
    color: var(--primary);
}

.testimonial-role {
    font-size: 0.85rem;
    color: var(--text-light);
}

/* ===== CONTACT SECTION ===== */
.contact {
    background: var(--light);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 60px;
}

.contact-info {
    padding: 40px;
    background: var(--primary);
    border-radius: 8px;
    color: var(--white);
}

.contact-info h3 {
    color: var(--white);
    margin-bottom: 20px;
    font-size: 1.5rem;
}

.contact-info p {
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 30px;
}

.contact-detail {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 25px;
}

.contact-detail-icon {
    width: 40px;
    height: 40px;
    background: rgba(201, 169, 110, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    flex-shrink: 0;
}

.contact-detail-text h4 {
    color: var(--white);
    font-family: var(--font-body);
    font-size: 0.9rem;
    margin-bottom: 3px;
}

.contact-detail-text p {
    color: rgba(255, 255, 255, 0.7);
    margin: 0;
    font-size: 0.9rem;
}

.contact-social {
    display: flex;
    gap: 12px;
    margin-top: 30px;
}

.social-link {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    transition: var(--transition);
}

.social-link:hover {
    background: var(--accent);
    transform: translateY(-3px);
}

/* Contact Form */
.contact-form {
    background: var(--white);
    padding: 40px;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    font-size: 0.9rem;
    color: var(--primary);
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 14px 18px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: var(--transition);
    background: var(--light);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(201, 169, 110, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 130px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.btn-submit {
    width: 100%;
    padding: 16px;
    font-size: 1rem;
}

/* ===== FOOTER ===== */
.site-footer {
    background: var(--dark);
    color: rgba(255, 255, 255, 0.7);
    padding: 80px 0 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1.5fr;
    gap: 40px;
    margin-bottom: 60px;
}

.footer-brand {
    max-width: 300px;
}

.footer-brand .nav-logo {
    display: inline-block;
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    line-height: 1.7;
}

.footer-heading {
    color: var(--white);
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9rem;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--accent);
    padding-left: 5px;
}

.footer-contact-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 15px;
    font-size: 0.9rem;
}

.footer-contact-item svg {
    flex-shrink: 0;
    color: var(--accent);
    margin-top: 3px;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 25px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
    margin: 0;
}

.footer-bottom-links {
    display: flex;
    gap: 20px;
}

.footer-bottom-links a {
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
}

.footer-bottom-links a:hover {
    color: var(--accent);
}

/* ===== BLOG PAGE ===== */
.blog-hero {
    background: var(--primary);
    padding: 140px 0 60px;
    text-align: center;
}

.blog-hero h1 {
    color: var(--white);
    margin-bottom: 10px;
}

.blog-hero p {
    color: rgba(255, 255, 255, 0.7);
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 30px;
    padding: 60px 0;
}

.blog-card {
    background: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.blog-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.blog-card-image {
    height: 220px;
    background: var(--primary);
    overflow: hidden;
}

.blog-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.blog-card:hover .blog-card-image img {
    transform: scale(1.05);
}

.blog-card-content {
    padding: 25px;
}

.blog-card-meta {
    display: flex;
    gap: 15px;
    margin-bottom: 12px;
    font-size: 0.8rem;
    color: var(--text-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.blog-card-content h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    transition: var(--transition);
}

.blog-card:hover .blog-card-content h3 {
    color: var(--accent);
}

.blog-card-content p {
    font-size: 0.9rem;
    margin-bottom: 15px;
}

.blog-read-more {
    color: var(--accent);
    font-weight: 600;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.blog-read-more:hover {
    gap: 10px;
}

/* Blog single */
.single-post-hero {
    background: var(--primary);
    padding: 140px 0 60px;
}

.single-post-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 60px 20px;
}

.single-post-content h1,
.single-post-content h2,
.single-post-content h3 {
    margin-top: 30px;
    margin-bottom: 15px;
}

.single-post-content p {
    font-size: 1.05rem;
    line-height: 1.9;
    margin-bottom: 20px;
}

.single-post-content img {
    border-radius: 8px;
    margin: 30px 0;
}

/* Pagination */
.pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    padding-bottom: 60px;
}

.pagination a,
.pagination span {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 4px;
    font-weight: 500;
    transition: var(--transition);
}

.pagination a {
    background: var(--light);
    color: var(--text);
}

.pagination a:hover {
    background: var(--accent);
    color: var(--white);
}

.pagination .current {
    background: var(--accent);
    color: var(--white);
}

/* ===== ANIMATIONS ===== */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-left.revealed {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-right.revealed {
    opacity: 1;
    transform: translateX(0);
}

.stagger-1 { transition-delay: 0.1s; }
.stagger-2 { transition-delay: 0.2s; }
.stagger-3 { transition-delay: 0.3s; }
.stagger-4 { transition-delay: 0.4s; }
.stagger-5 { transition-delay: 0.5s; }
.stagger-6 { transition-delay: 0.6s; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
    .about-grid,
    .contact-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .about-image::before {
        display: none;
    }
}

@media (max-width: 768px) {
    .section {
        padding: 70px 0;
    }

    .nav-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 80%;
        max-width: 350px;
        height: 100vh;
        background: var(--primary);
        flex-direction: column;
        justify-content: center;
        gap: 25px;
        padding: 40px;
        transition: right 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.3);
    }

    .nav-menu.active {
        right: 0;
    }

    .nav-menu .nav-link,
    .site-header.scrolled .nav-menu .nav-link {
        color: var(--white);
        font-size: 1.1rem;
    }

    .nav-cta,
    .site-header.scrolled .nav-cta {
        color: var(--white) !important;
    }

    .nav-toggle {
        display: flex;
    }

    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }

    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
    }

    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(5px, -5px);
    }

    .hero-buttons {
        flex-direction: column;
    }

    .about-stats {
        grid-template-columns: repeat(3, 1fr);
    }

    .services-grid {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .blog-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .about-stats {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .hero-content {
        padding: 0 15px;
    }

    .clients-logos {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ===== UTILITIES ===== */
.text-accent { color: var(--accent); }
.bg-light { background: var(--light); }
.bg-primary { background: var(--primary); }

/* Overlay for mobile menu */
.nav-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.nav-overlay.active {
    opacity: 1;
    pointer-events: all;
}

/* Loading animation */
.page-loader {
    position: fixed;
    inset: 0;
    background: var(--primary);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.page-loader.loaded {
    opacity: 0;
    visibility: hidden;
}

.loader-text {
    font-family: var(--font-heading);
    font-size: 2rem;
    color: var(--white);
    animation: pulse 1.5s ease-in-out infinite;
}

.loader-text span {
    color: var(--accent);
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

/* Scroll to top button */
.scroll-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 45px;
    height: 45px;
    background: var(--accent);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 99;
    border: none;
    box-shadow: 0 4px 15px rgba(201, 169, 110, 0.4);
}

.scroll-top.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(201, 169, 110, 0.5);
}
