/* ========================================
   Cardinal Painting Pros — Custom Styles
   ======================================== */

/* --- CSS Custom Properties --- */
:root {
    --emerald-50: #ecfdf5;
    --emerald-100: #d1fae5;
    --emerald-200: #a7f3d0;
    --emerald-300: #6ee7b7;
    --emerald-400: #34d399;
    --emerald-500: #10b981;
    --emerald-600: #059669;
    --emerald-700: #047857;
    --emerald-800: #065f46;
    --emerald-900: #064e3b;
    --emerald-950: #022c22;
    --cream-50: #fefdf8;
    --cream-100: #fdf9f0;
    --cream-200: #faf3e0;
}

/* --- Base & Typography --- */
html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

::selection {
    background-color: var(--emerald-200);
    color: var(--emerald-950);
}

/* --- Fixed Background Geometric Shapes --- */
.geo-shape {
    position: fixed;
    pointer-events: none;
    z-index: 0;
    opacity: 0.4;
}

.shape-circle-1 {
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--emerald-200) 0%, transparent 70%);
    top: -100px;
    right: -100px;
    animation: floatShape 20s ease-in-out infinite;
}

.shape-circle-2 {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--emerald-100) 0%, transparent 70%);
    bottom: 10%;
    left: -80px;
    animation: floatShape 25s ease-in-out infinite reverse;
}

.shape-rect-1 {
    width: 200px;
    height: 200px;
    background: var(--emerald-100);
    border-radius: 30px;
    top: 40%;
    right: 5%;
    transform: rotate(45deg);
    opacity: 0.2;
    animation: floatShape 18s ease-in-out infinite;
}

.shape-triangle-1 {
    width: 0;
    height: 0;
    border-left: 80px solid transparent;
    border-right: 80px solid transparent;
    border-bottom: 140px solid var(--emerald-200);
    opacity: 0.15;
    top: 60%;
    left: 3%;
    animation: floatShape 22s ease-in-out infinite reverse;
}

@keyframes floatShape {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-20px) rotate(3deg); }
    50% { transform: translateY(10px) rotate(-2deg); }
    75% { transform: translateY(-15px) rotate(1deg); }
}

/* --- Navbar --- */
.nav-header {
    background: rgba(254, 253, 248, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(6, 95, 70, 0.08);
}

.nav-header.scrolled {
    box-shadow: 0 4px 20px rgba(6, 78, 59, 0.08);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--emerald-600);
    transition: width 0.3s ease;
}

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

/* --- Buttons --- */
.btn-primary {
    background: var(--emerald-700);
    color: white;
    font-weight: 600;
    padding: 14px 28px;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 2px solid var(--emerald-700);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-primary:hover {
    background: var(--emerald-600);
    border-color: var(--emerald-600);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(5, 150, 105, 0.3);
    color: white;
}

.btn-secondary {
    background: transparent;
    color: var(--emerald-700);
    font-weight: 600;
    padding: 14px 28px;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 2px solid var(--emerald-200);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-secondary:hover {
    background: var(--emerald-50);
    border-color: var(--emerald-400);
    transform: translateY(-2px);
    color: var(--emerald-700);
}

/* --- Section Headers --- */
.section-tag {
    font-size: 0.8125rem;
    letter-spacing: 0.025em;
}

.section-title {
    font-size: 2.25rem;
    line-height: 1.15;
}

.section-subtitle {
    font-size: 1.125rem;
}

/* --- Hero --- */
.hero-title {
    font-size: clamp(2.25rem, 5vw, 4.5rem);
}

.hero-subtitle {
    font-size: clamp(1rem, 2vw, 1.25rem);
}

.hero-geo {
    position: absolute;
    border-radius: 50%;
    opacity: 0.12;
}

.hero-geo-1 {
    width: 500px;
    height: 500px;
    background: var(--emerald-500);
    top: -150px;
    right: -100px;
    animation: heroFloat 12s ease-in-out infinite;
}

.hero-geo-2 {
    width: 300px;
    height: 300px;
    background: var(--emerald-400);
    bottom: -80px;
    left: 10%;
    animation: heroFloat 15s ease-in-out infinite reverse;
}

.hero-geo-3 {
    width: 150px;
    height: 150px;
    background: var(--emerald-300);
    top: 30%;
    left: 5%;
    animation: heroFloat 10s ease-in-out infinite;
}

@keyframes heroFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    33% { transform: translate(20px, -30px) scale(1.05); }
    66% { transform: translate(-15px, 20px) scale(0.95); }
}

.hero-float-card {
    animation: floatCard 6s ease-in-out infinite;
}

@keyframes floatCard {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.scroll-indicator {
    animation: bounce 2s ease-in-out infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(6px); }
}

/* --- Service Cards --- */
.service-card {
    position: relative;
}

.service-card-inner {
    position: relative;
    overflow: hidden;
}

.service-card-inner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--emerald-400), var(--emerald-600));
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease;
}

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

/* --- About --- */
.about-img-stack-1 {
    box-shadow: 0 20px 50px rgba(6, 78, 59, 0.2);
}

.about-img-stack-2 {
    box-shadow: 0 20px 50px rgba(6, 78, 59, 0.15);
}

.about-exp-badge {
    z-index: 10;
}

/* --- Gallery --- */
.gallery-item {
    cursor: pointer;
}

.gallery-item img {
    transition: transform 0.6s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
}

/* --- Testimonials --- */
.testimonial-card {
    position: relative;
}

.testimonial-card::before {
    content: '"';
    position: absolute;
    top: -10px;
    left: 20px;
    font-size: 6rem;
    font-family: 'Playfair Display', serif;
    color: var(--emerald-100);
    line-height: 1;
    z-index: 0;
    pointer-events: none;
}

.testimonial-card > * {
    position: relative;
    z-index: 1;
}

/* --- Process --- */
.process-step {
    position: relative;
}

.process-number {
    box-shadow: 0 8px 25px rgba(5, 150, 105, 0.3);
}

.process-connector {
    background: repeating-linear-gradient(90deg, var(--emerald-200), var(--emerald-200) 8px, transparent 8px, transparent 16px);
}

/* --- Contact Form --- */
.form-input,
.form-select,
.form-textarea {
    background: var(--cream-50);
    border: 2px solid var(--emerald-100);
    border-radius: 10px;
    padding: 12px 16px;
    font-family: 'Outfit', sans-serif;
    font-size: 1rem;
    color: var(--emerald-950);
    transition: all 0.3s ease;
    width: 100%;
    box-sizing: border-box;
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--emerald-500);
    background: white;
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.1);
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: var(--emerald-400);
}

.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23065f46' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
    cursor: pointer;
}

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

.contact-info-card {
    transition: transform 0.3s ease;
}

.contact-info-card:hover {
    transform: translateX(4px);
}

/* --- Back to Top --- */
.back-to-top {
    opacity: 0;
    pointer-events: none;
    transform: translateY(20px);
    transition: all 0.3s ease;
}

.back-to-top.visible {
    opacity: 1;
    pointer-events: all;
    transform: translateY(0);
}

/* --- Mobile Menu --- */
.mobile-menu {
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.mobile-nav-link {
    position: relative;
}

/* --- Responsive --- */
@media (max-width: 767px) {
    .section-title {
        font-size: 1.875rem;
    }
    
    .section-subtitle {
        font-size: 1rem;
    }
    
    .hero-float-card {
        position: relative;
        bottom: auto;
        left: auto;
        margin-top: 1rem;
        max-width: 100%;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .section-title {
        font-size: 2.5rem;
    }
}

/* --- Reduced Motion --- */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* --- Print --- */
@media print {
    .geo-shape,
    .hero-geo,
    .back-to-top,
    .scroll-indicator {
        display: none !important;
    }
    
    .nav-header {
        position: static;
        background: white;
    }
}
