/* ============================================
   Robert Stewart Agency - Custom Styles
   Theme: Charcoal + Coral, Minimalist, Thin Typography
   ============================================ */

/* CSS Custom Properties */
:root {
    /* Color Palette */
    --color-charcoal: #1a1a1a;
    --color-charcoal-light: #2d2d2d;
    --color-charcoal-muted: #4a4a4a;
    --color-coral: #e07a5f;
    --color-coral-light: #e8956f;
    --color-coral-dark: #c4624a;
    --color-cream: #faf8f5;
    --color-off-white: #f5f3f0;
    --color-white: #ffffff;
    --color-border: #e5e2dd;
    --color-text: #333333;
    --color-text-light: #666666;
    
    /* Typography */
    --font-serif: 'Cormorant Garamond', Georgia, serif;
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    
    /* Spacing */
    --space-xs: 0.5rem;
    --space-sm: 1rem;
    --space-md: 2rem;
    --space-lg: 4rem;
    --space-xl: 6rem;
    --space-2xl: 8rem;
    
    /* Transitions */
    --transition-fast: 0.2s ease;
    --transition-base: 0.3s ease;
    --transition-slow: 0.5s ease;
    
    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 16px;
}

/* Reset & Base */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

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

body {
    font-family: var(--font-sans);
    font-weight: 300;
    line-height: 1.7;
    color: var(--color-text);
    background-color: var(--color-cream);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

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

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

button {
    cursor: pointer;
    border: none;
    background: none;
    font-family: inherit;
}

/* Container */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-md);
}

/* Typography */
h1, h2, h3, h4 {
    font-family: var(--font-serif);
    font-weight: 400;
    line-height: 1.2;
    color: var(--color-charcoal);
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(250, 248, 245, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--color-border);
    transition: all var(--transition-base);
}

.navbar.scrolled {
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.05);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-serif);
    font-size: 1.25rem;
    font-weight: 500;
    color: var(--color-charcoal);
    letter-spacing: 0.02em;
}

.logo-mark {
    width: 32px;
    height: 32px;
    background: var(--color-coral);
    position: relative;
}

.logo-mark::before {
    content: '';
    position: absolute;
    top: 8px;
    left: 8px;
    right: 8px;
    bottom: 8px;
    background: var(--color-cream);
}

.nav-links {
    display: flex;
    align-items: center;
    gap: var(--space-md);
    list-style: none;
}

.nav-links a {
    font-size: 0.875rem;
    font-weight: 400;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--color-charcoal-muted);
    transition: color var(--transition-fast);
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: var(--color-coral);
    transition: width var(--transition-base);
}

.nav-links a:hover {
    color: var(--color-charcoal);
}

.nav-links a::after {
    width: 100%;
}

.btn-nav {
    padding: 10px 24px;
    border: 1px solid var(--color-charcoal) !important;
    text-transform: uppercase !important;
    letter-spacing: 0.1em !important;
    transition: all var(--transition-fast) !important;
}

.btn-nav:hover {
    background: var(--color-charcoal);
    color: var(--color-white) !important;
}

.btn-nav::after {
    display: none !important;
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 6px;
    padding: 8px;
    z-index: 1001;
}

.mobile-menu-btn span {
    width: 24px;
    height: 1.5px;
    background: var(--color-charcoal);
    transition: all var(--transition-base);
}

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

.mobile-menu-btn.active span:nth-child(2) {
    opacity: 0;
}

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

/* Mobile Menu Overlay */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--color-cream);
    z-index: 999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-base);
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-close {
    position: absolute;
    top: 24px;
    right: 24px;
    color: var(--color-charcoal);
}

.mobile-menu-overlay ul {
    list-style: none;
    text-align: center;
}

.mobile-menu-overlay li {
    margin: var(--space-sm) 0;
}

.mobile-link {
    font-family: var(--font-serif);
    font-size: 2rem;
    color: var(--color-charcoal);
    transition: color var(--transition-fast);
}

.mobile-link:hover {
    color: var(--color-coral);
}

/* Hero Section */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 50%, #3d2b1f 100%);
}

.hero-gradient {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(224, 122, 95, 0.15) 0%, 
        rgba(26, 26, 26, 0.9) 50%,
        rgba(224, 122, 95, 0.1) 100%);
    pointer-events: none;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,%3Csvg width="60" height="60" viewBox="0 0 60 60" xmlns="http://www.w3.org/2000/svg"%3E%3Cg fill="none" fill-rule="evenodd"%3E%3Cg fill="%23ffffff" fill-opacity="0.02"%3E%3Cpath d="M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z"/%3E%3C/g%3E%3C/g%3E%3C/svg%3E');
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 800px;
    padding: var(--space-lg) var(--space-md);
}

.hero-headline {
    font-family: var(--font-serif);
    font-size: clamp(3rem, 8vw, 5.5rem);
    font-weight: 400;
    color: var(--color-white);
    margin-bottom: var(--space-md);
    letter-spacing: -0.02em;
    line-height: 1.1;
}

.hero-subheadline {
    font-size: clamp(1rem, 2vw, 1.25rem);
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: var(--space-lg);
    font-weight: 300;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.hero-cta {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-md);
    flex-wrap: wrap;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 32px;
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    border-radius: var(--radius-sm);
    transition: all var(--transition-base);
}

.btn-primary {
    background: var(--color-coral);
    color: var(--color-white);
    border: 2px solid var(--color-coral);
}

.btn-primary:hover {
    background: var(--color-coral-dark);
    border-color: var(--color-coral-dark);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(224, 122, 95, 0.3);
}

.btn-text {
    background: transparent;
    color: var(--color-white);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.btn-text:hover {
    border-color: var(--color-white);
    background: rgba(255, 255, 255, 0.1);
}

.btn-full {
    width: 100%;
}

/* Hero Scroll Indicator */
.hero-scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.75rem;
    letter-spacing: 0.2em;
    text-transform: uppercase;
}

.scroll-line {
    width: 1px;
    height: 60px;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0.5), transparent);
    animation: scrollLine 2s ease-in-out infinite;
}

@keyframes scrollLine {
    0%, 100% {
        opacity: 0;
        transform: scaleY(0);
        transform-origin: top;
    }
    50% {
        opacity: 1;
        transform: scaleY(1);
    }
}

/* Sections */
.section {
    padding: var(--space-2xl) 0;
}

.section-header {
    text-align: center;
    max-width: 700px;
    margin: 0 auto var(--space-xl);
}

.section-tag {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--color-coral);
    margin-bottom: var(--space-sm);
}

.section-title {
    font-size: clamp(2rem, 5vw, 3rem);
    margin-bottom: var(--space-md);
    color: var(--color-charcoal);
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--color-text-light);
    line-height: 1.8;
}

/* About Section */
.about {
    background: var(--color-cream);
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
    align-items: center;
    margin-bottom: var(--space-xl);
}

.about-text {
    max-width: 500px;
}

.about-text .lead {
    font-family: var(--font-serif);
    font-size: 1.5rem;
    line-height: 1.5;
    color: var(--color-charcoal);
    margin-bottom: var(--space-md);
}

.about-text p {
    margin-bottom: var(--space-md);
    color: var(--color-text-light);
}

.about-image {
    position: relative;
}

.about-image img {
    width: 100%;
    height: 500px;
    object-fit: cover;
    border-radius: var(--radius-md);
}

.image-accent {
    position: absolute;
    bottom: -20px;
    right: -20px;
    width: 150px;
    height: 150px;
    background: var(--color-coral);
    opacity: 0.1;
    border-radius: var(--radius-md);
    z-index: -1;
}

.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--space-md);
    padding-top: var(--space-lg);
    border-top: 1px solid var(--color-border);
}

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

.stat-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    color: var(--color-coral);
    margin-bottom: 4px;
}

.stat-value {
    display: block;
    font-family: var(--font-serif);
    font-size: 1.75rem;
    color: var(--color-charcoal);
    margin-bottom: 4px;
}

.stat-sub {
    display: block;
    font-size: 0.875rem;
    color: var(--color-text-light);
}

.stat-divider {
    width: 1px;
    background: var(--color-border);
    align-self: stretch;
}

/* Services Section */
.services {
    background: var(--color-white);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--space-md);
}

.service-card {
    padding: var(--space-lg);
    background: var(--color-cream);
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
    border: 1px solid transparent;
}

.service-card:hover {
    transform: translateY(-4px);
    border-color: var(--color-coral);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

.service-icon {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-white);
    border-radius: var(--radius-sm);
    margin-bottom: var(--space-md);
    color: var(--color-coral);
    border: 1px solid var(--color-border);
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: var(--space-sm);
    color: var(--color-charcoal);
}

.service-card p {
    color: var(--color-text-light);
    line-height: 1.8;
}

/* Why Us Section */
.why-us {
    background: var(--color-charcoal);
    color: var(--color-white);
}

.why-us .section-tag {
    color: var(--color-coral-light);
}

.why-us .section-title {
    color: var(--color-white);
}

.why-us .section-subtitle {
    color: rgba(255, 255, 255, 0.6);
}

.split-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--space-xl);
    align-items: center;
}

.split-content {
    max-width: 500px;
}

.values-list {
    margin-top: var(--space-lg);
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.value-item {
    display: flex;
    gap: var(--space-md);
    align-items: flex-start;
}

.value-marker {
    width: 24px;
    height: 24px;
    min-width: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--color-coral);
    border-radius: 50%;
    color: var(--color-coral);
    margin-top: 4px;
}

.value-item h4 {
    font-family: var(--font-serif);
    font-size: 1.25rem;
    color: var(--color-white);
    margin-bottom: 4px;
}

.value-item p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9375rem;
    line-height: 1.7;
}

.split-image img {
    width: 100%;
    height: 600px;
    object-fit: cover;
    border-radius: var(--radius-md);
}

/* Contact Section */
.contact {
    background: var(--color-cream);
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: var(--space-xl);
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.info-item {
    display: flex;
    gap: var(--space-md);
    align-items: flex-start;
}

.info-icon {
    width: 48px;
    height: 48px;
    min-width: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-white);
    border-radius: var(--radius-sm);
    color: var(--color-coral);
    border: 1px solid var(--color-border);
}

.info-item h4 {
    font-family: var(--font-serif);
    font-size: 1.125rem;
    color: var(--color-charcoal);
    margin-bottom: 4px;
}

.info-item p {
    color: var(--color-text-light);
    line-height: 1.6;
}

.info-item a {
    color: var(--color-charcoal);
    transition: color var(--transition-fast);
}

.info-item a:hover {
    color: var(--color-coral);
}

.map-container {
    margin-top: var(--space-md);
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--color-border);
}

.contact-form-wrapper {
    background: var(--color-white);
    padding: var(--space-lg);
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border);
}

.contact-form {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--color-charcoal-muted);
}

.form-group input,
.form-group textarea {
    padding: 14px 16px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    font-family: var(--font-sans);
    font-size: 1rem;
    color: var(--color-charcoal);
    background: var(--color-cream);
    transition: all var(--transition-fast);
    outline: none;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--color-coral);
    background: var(--color-white);
    box-shadow: 0 0 0 3px rgba(224, 122, 95, 0.1);
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: var(--color-text-light);
}

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

.form-success {
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: var(--space-xl);
}

.form-success.active {
    display: flex;
}

.success-icon {
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-cream);
    border-radius: 50%;
    margin-bottom: var(--space-md);
    color: var(--color-coral);
}

.form-success h3 {
    font-size: 1.75rem;
    margin-bottom: var(--space-sm);
}

.form-success p {
    color: var(--color-text-light);
    margin-bottom: var(--space-md);
}

/* Footer */
.footer {
    background: var(--color-charcoal);
    color: var(--color-white);
    padding: var(--space-xl) 0 var(--space-md);
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: var(--space-xl);
    margin-bottom: var(--space-xl);
}

.footer-brand .logo {
    color: var(--color-white);
    margin-bottom: var(--space-md);
}

.footer-brand p {
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.8;
    max-width: 300px;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

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

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

.footer-contact {
    display: flex;
    flex-direction: column;
    gap: var(--space-sm);
}

.footer-contact p {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.9375rem;
}

.footer-contact a {
    color: rgba(255, 255, 255, 0.6);
    transition: color var(--transition-fast);
}

.footer-contact a:hover {
    color: var(--color-coral);
}

.footer-bottom {
    padding-top: var(--space-md);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    text-align: center;
}

.footer-bottom p {
    color: rgba(255, 255, 255, 0.4);
    font-size: 0.875rem;
}

/* Responsive Styles */
@media (max-width: 1024px) {
    .about-content,
    .split-layout {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }
    
    .about-text {
        max-width: 100%;
    }
    
    .about-image img,
    .split-image img {
        height: 400px;
    }
    
    .contact-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    :root {
        --space-lg: 3rem;
        --space-xl: 4rem;
        --space-2xl: 5rem;
    }
    
    .nav-links {
        display: none;
    }
    
    .mobile-menu-btn {
        display: flex;
    }
    
    .hero-headline {
        font-size: clamp(2.5rem, 10vw, 4rem);
    }
    
    .stats-row {
        grid-template-columns: 1fr;
        gap: var(--space-md);
    }
    
    .stat-divider {
        display: none;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: var(--space-lg);
    }
    
    .contact-form-wrapper {
        padding: var(--space-md);
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 var(--space-sm);
    }
    
    .hero-cta {
        flex-direction: column;
        width: 100%;
    }
    
    .btn {
        width: 100%;
        text-align: center;
    }
    
    .service-card {
        padding: var(--space-md);
    }
    
    .value-item {
        flex-direction: column;
        gap: var(--space-sm);
    }
}

/* Accessibility */
@media (prefers-reduced-motion: no-preference) {
    .scroll-line {
        animation: scrollLine 2s ease-in-out infinite;
    }
}

@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;
    }
}

/* Focus styles */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--color-coral);
    outline-offset: 2px;
}

/* Print styles */
@media print {
    .navbar,
    .hero-scroll-indicator,
    .mobile-menu-overlay {
        display: none;
    }
    
    body {
        color: #000;
        background: #fff;
    }
    
    .hero {
        min-height: auto;
        padding: var(--space-lg) 0;
        background: #fff !important;
        color: #000 !important;
    }
    
    .hero-headline,
    .hero-subheadline {
        color: #000 !important;
    }
}
