* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --charleston-navy: #1e293b;
    --charleston-slate: #334155;
    --charleston-cream: #fefcf8;
    --charleston-sage: #6b7280;
    --charleston-gold: #d4af37;
    --charleston-brick: #b45309;
    --tech-blue: #1e40af;
    --tech-cyan: #0891b2;
    --tech-purple: #7c3aed;
    --wrought-iron: #374151;
    --accent-coral: #f97316;
    --subtle-border: rgba(30, 64, 175, 0.08);
    --glass-bg: rgba(254, 252, 248, 0.85);
}

body {
    font-family: 'Source Sans Pro', sans-serif;
    line-height: 1.65;
    color: var(--charleston-navy);
    background: var(--charleston-cream);
    overflow-x: hidden;
    font-weight: 400;
}

/* Sophisticated background with Charleston architectural elements */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 80%, rgba(30, 64, 175, 0.02) 0%, transparent 60%),
        radial-gradient(circle at 80% 20%, rgba(124, 58, 237, 0.02) 0%, transparent 60%),
        linear-gradient(135deg, rgba(212, 175, 55, 0.01) 0%, transparent 50%),
        url("data:image/svg+xml,%3Csvg width='120' height='120' viewBox='0 0 120 120' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' stroke='%231e40af' stroke-width='0.5' opacity='0.03'%3E%3Cpath d='M20 20h80v80H20z'/%3E%3Cpath d='M30 30h20v20H30z'/%3E%3Cpath d='M70 30h20v20H70z'/%3E%3Cpath d='M30 70h20v20H30z'/%3E%3Cpath d='M70 70h20v20H70z'/%3E%3Ccircle cx='60' cy='60' r='3'/%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
    z-index: -1;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Elegant header inspired by Charleston ironwork */
header {
    background: var(--glass-bg);
    backdrop-filter: blur(24px);
    border-bottom: 1px solid var(--subtle-border);
    box-shadow: 0 8px 32px rgba(30, 41, 59, 0.06);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem 0;
}

.logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    text-decoration: none;
    color: var(--charleston-navy);
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: translateY(-1px);
}

/* Charleston street sign inspired logo */
.logo-icon {
    width: 60px;
    height: 36px;
    background: linear-gradient(135deg, var(--charleston-navy) 0%, var(--charleston-slate) 100%);
    border-radius: 6px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--charleston-navy);
    box-shadow: 0 4px 12px rgba(30, 41, 59, 0.15);
}

.logo-icon::before {
    content: 'PALM ST';
    color: var(--charleston-cream);
    font-family: 'Playfair Display', serif;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.8px;
}

.logo-icon::after {
    content: '';
    position: absolute;
    top: -2px;
    right: -2px;
    width: 8px;
    height: 8px;
    background: var(--tech-cyan);
    border-radius: 50%;
    box-shadow: 0 0 8px rgba(8, 145, 178, 0.6);
}

.logo-text {
    font-family: 'Playfair Display', serif;
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--charleston-navy);
    letter-spacing: -0.02em;
}

.logo-subtext {
    font-size: 0.8rem;
    color: var(--charleston-sage);
    font-weight: 500;
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-top: -2px;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 2.5rem;
}

.nav-links a {
    text-decoration: none;
    color: var(--charleston-slate);
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    padding: 0.5rem 0;
    letter-spacing: 0.3px;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--tech-blue), var(--tech-cyan));
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateX(-50%);
}

.nav-links a:hover {
    color: var(--tech-blue);
    transform: translateY(-1px);
}

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

/* Sophisticated hero section */
.hero {
    padding: 160px 0 120px;
    position: relative;
    background: linear-gradient(135deg, 
        var(--charleston-cream) 0%, 
        rgba(254, 252, 248, 0.9) 40%,
        rgba(30, 64, 175, 0.03) 70%,
        var(--charleston-cream) 100%);
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='200' height='200' viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' stroke='%231e40af' stroke-width='0.3' opacity='0.06'%3E%3Cpath d='M50 50h100v100H50z'/%3E%3Cpath d='M70 70h60v60H70z'/%3E%3Cpath d='M80 30v140M120 30v140M30 80h140M30 120h140'/%3E%3Ccircle cx='100' cy='100' r='8'/%3E%3Ccircle cx='100' cy='100' r='16'/%3E%3C/g%3E%3C/svg%3E") repeat;
    opacity: 0.4;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
    max-width: 900px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-block;
    background: linear-gradient(135deg, var(--tech-blue), var(--tech-purple));
    color: white;
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin-bottom: 2rem;
    animation: fadeInUp 0.8s ease;
}

.hero h1 {
    font-family: 'Playfair Display', serif;
    font-size: 4.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    color: var(--charleston-navy);
    line-height: 1.1;
    letter-spacing: -0.02em;
    animation: fadeInUp 1s ease 0.2s both;
}

.hero h1 .accent {
    background: linear-gradient(135deg, var(--tech-blue), var(--tech-purple));
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-size: 200% 200%;
    animation: gradientShift 3s ease-in-out infinite;
}

.hero-subtitle {
    font-size: 1.4rem;
    color: var(--charleston-sage);
    margin-bottom: 2rem;
    font-weight: 400;
    letter-spacing: 0.3px;
    animation: fadeInUp 1s ease 0.4s both;
}

.hero-description {
    font-size: 1.15rem;
    color: var(--charleston-slate);
    max-width: 700px;
    margin: 0 auto 3rem;
    line-height: 1.7;
    animation: fadeInUp 1s ease 0.6s both;
}

.cta-group {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
    animation: fadeInUp 1s ease 0.8s both;
}

.cta-button {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, var(--tech-blue), var(--tech-purple));
    color: white;
    padding: 18px 32px;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 1rem;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 8px 32px rgba(30, 64, 175, 0.25);
    position: relative;
    overflow: hidden;
    letter-spacing: 0.3px;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.6s ease;
}

.cta-button:hover::before {
    left: 100%;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 48px rgba(30, 64, 175, 0.35);
}

.cta-secondary {
    background: transparent;
    color: var(--charleston-slate);
    border: 2px solid var(--subtle-border);
    backdrop-filter: blur(12px);
}

.cta-secondary:hover {
    background: var(--charleston-navy);
    color: white;
    border-color: var(--charleston-navy);
}

/* Professional services section */
.services {
    padding: 120px 0;
    background: white;
    position: relative;
}

.services::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--subtle-border), transparent);
}

.section-header {
    text-align: center;
    margin-bottom: 5rem;
}

.section-badge {
    display: inline-block;
    background: var(--tech-blue);
    color: white;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-bottom: 1.5rem;
}

.section-title {
    font-family: 'Playfair Display', serif;
    font-size: 3.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--charleston-navy);
    letter-spacing: -0.02em;
}

.section-subtitle {
    color: var(--charleston-sage);
    font-size: 1.2rem;
    max-width: 700px;
    margin: 0 auto;
    line-height: 1.6;
}

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

.service-card {
    background: white;
    padding: 3rem 2.5rem;
    border-radius: 20px;
    text-align: left;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--subtle-border);
    position: relative;
    overflow: hidden;
    group: service-card;
}

.service-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 6px;
    background: linear-gradient(90deg, var(--tech-blue), var(--tech-purple));
    transform: scaleX(0);
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: left;
}

.service-card::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(30, 64, 175, 0.03) 0%, transparent 70%);
    opacity: 0;
    transition: opacity 0.5s ease;
}

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

.service-card:hover::after {
    opacity: 1;
}

.service-card:hover {
    transform: translateY(-12px);
    box-shadow: 0 32px 64px rgba(30, 41, 59, 0.15);
    border-color: rgba(30, 64, 175, 0.15);
}

.service-icon {
    font-size: 3rem;
    margin-bottom: 2rem;
    display: block;
    filter: grayscale(0.3);
    transition: filter 0.3s ease;
}

.service-card:hover .service-icon {
    filter: grayscale(0);
}

.service-card h3 {
    font-family: 'Playfair Display', serif;
    font-size: 1.75rem;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--charleston-navy);
    letter-spacing: -0.01em;
}

.service-card p {
    color: var(--charleston-sage);
    line-height: 1.7;
    font-size: 1rem;
}

.service-features {
    margin-top: 1.5rem;
    list-style: none;
}

.service-features li {
    padding: 0.3rem 0;
    color: var(--charleston-slate);
    font-size: 0.9rem;
    position: relative;
    padding-left: 1.2rem;
}

.service-features li::before {
    content: '▸';
    color: var(--tech-blue);
    font-weight: bold;
    position: absolute;
    left: 0;
}

/* Charleston heritage section */
.charleston {
    background: var(--charleston-navy);
    color: var(--charleston-cream);
    padding: 120px 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.charleston::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='160' height='160' viewBox='0 0 160 160' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' stroke='%23fefcf8' stroke-width='0.5' opacity='0.03'%3E%3Cpath d='M40 40h80v80H40z'/%3E%3Cpath d='M60 20v120M100 20v120M20 60h120M20 100h120'/%3E%3Ccircle cx='80' cy='80' r='12'/%3E%3Cpath d='M60 60h40v40H60z'/%3E%3C/g%3E%3C/svg%3E") repeat;
    pointer-events: none;
}

.charleston-content {
    position: relative;
    z-index: 2;
    max-width: 900px;
    margin: 0 auto;
}

.charleston .section-title {
    color: var(--charleston-cream);
    margin-bottom: 2rem;
}

.charleston p {
    font-size: 1.3rem;
    opacity: 0.95;
    line-height: 1.8;
    font-weight: 400;
}

.charleston-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 3rem;
    margin-top: 4rem;
    padding-top: 3rem;
    border-top: 1px solid rgba(254, 252, 248, 0.1);
}

.stat {
    text-align: center;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--charleston-gold);
    font-family: 'Playfair Display', serif;
}

.stat-label {
    font-size: 0.9rem;
    opacity: 0.8;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 0.5rem;
}

/* Professional contact section */
.contact {
    background: var(--charleston-cream);
    padding: 120px 0;
    text-align: center;
    position: relative;
}

.contact-info {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    max-width: 1000px;
    margin: 0 auto;
}

.contact-item {
    padding: 3rem 2.5rem;
    background: white;
    border-radius: 20px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid var(--subtle-border);
    text-align: center;
    position: relative;
    overflow: hidden;
}

.contact-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--tech-blue), var(--tech-purple));
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.contact-item:hover::before {
    transform: scaleX(1);
}

.contact-item:hover {
    transform: translateY(-8px);
    box-shadow: 0 24px 48px rgba(30, 41, 59, 0.12);
}

.contact-item h3 {
    font-family: 'Playfair Display', serif;
    color: var(--tech-blue);
    margin-bottom: 1rem;
    font-weight: 600;
    font-size: 1.3rem;
}

.contact-item p {
    color: var(--charleston-sage);
    font-size: 1rem;
    line-height: 1.6;
}

.contact-item a {
    color: var(--tech-blue);
    text-decoration: none;
    transition: color 0.3s ease;
    font-weight: 500;
}

.contact-item a:hover {
    color: var(--tech-purple);
}

footer {
    background: var(--charleston-navy);
    color: var(--charleston-cream);
    text-align: center;
    padding: 3rem 0;
    opacity: 0.9;
    position: relative;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(254, 252, 248, 0.1), transparent);
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes gradientShift {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    .hero h1 {
        font-size: 3.2rem;
    }
    
    .section-title {
        font-size: 2.8rem;
    }
    
    .nav-links {
        display: none;
    }
    
    .services-grid,
    .contact-info {
        grid-template-columns: 1fr;
    }

    .logo-text {
        font-size: 1.4rem;
    }

    .container {
        padding: 0 18px;
    }

    .cta-group {
        flex-direction: column;
        align-items: center;
    }

    .charleston-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 2rem;
    }

    .service-card,
    .contact-item {
        padding: 2.5rem 2rem;
    }
}

/* Scroll animations */
@media (prefers-reduced-motion: no-preference) {
    .service-card {
        opacity: 0;
        transform: translateY(30px);
        animation: fadeInUp 0.7s ease forwards;
    }

    .service-card:nth-child(1) { animation-delay: 0.1s; }
    .service-card:nth-child(2) { animation-delay: 0.2s; }
    .service-card:nth-child(3) { animation-delay: 0.3s; }
    .service-card:nth-child(4) { animation-delay: 0.4s; }
    .service-card:nth-child(5) { animation-delay: 0.5s; }
    .service-card:nth-child(6) { animation-delay: 0.6s; }

    .contact-item {
        opacity: 0;
        transform: translateY(30px);
        animation: fadeInUp 0.7s ease forwards;
    }

    .contact-item:nth-child(1) { animation-delay: 0.2s; }
    .contact-item:nth-child(2) { animation-delay: 0.4s; }
    .contact-item:nth-child(3) { animation-delay: 0.6s; }
}

/* Advanced interactions */
.service-card {
    cursor: pointer;
}

.service-card:active {
    transform: translateY(-8px);
}

/* Micro-interactions */
.cta-button,
.contact-item a,
.nav-links a {
    position: relative;
}

.hero-badge {
    position: relative;
}

.hero-badge::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    padding: 1px;
    background: linear-gradient(135deg, rgba(255,255,255,0.3), rgba(255,255,255,0.1));
    mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    mask-composite: exclude;
}

/* ---- Service card link (index → detail pages) ---- */
.service-link {
    display: inline-block;
    margin-top: 1.5rem;
    color: var(--tech-blue);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    letter-spacing: 0.01em;
    transition: color 0.3s ease, transform 0.3s ease;
}

.service-link:hover {
    color: var(--tech-cyan);
    transform: translateX(4px);
}

/* ---- Detail page: page hero + prose sections ---- */
.page-hero {
    padding: 180px 0 80px;
    background: linear-gradient(135deg,
        var(--charleston-cream) 0%,
        rgba(30, 64, 175, 0.04) 60%,
        var(--charleston-cream) 100%);
}

.page-hero .section-title {
    font-size: 3rem;
    max-width: 20ch;
}

.page-hero .lead {
    font-size: 1.25rem;
    color: var(--charleston-slate);
    max-width: 60ch;
    margin-top: 1rem;
}

.breadcrumb {
    font-size: 0.9rem;
    color: var(--charleston-sage);
    margin-bottom: 1.5rem;
}

.breadcrumb a {
    color: var(--tech-blue);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.prose {
    padding: 80px 0;
}

.prose article {
    max-width: 72ch;
    margin: 0 auto 4rem;
}

.prose article:last-child {
    margin-bottom: 0;
}

.prose h2 {
    font-family: 'Playfair Display', serif;
    font-size: 2rem;
    font-weight: 600;
    color: var(--charleston-navy);
    letter-spacing: -0.01em;
    margin-bottom: 1.25rem;
    line-height: 1.25;
}

.prose p {
    color: var(--charleston-slate);
    margin-bottom: 1.25rem;
}

.prose ul {
    list-style: none;
    margin: 0 0 1.5rem;
}

.prose ul li {
    position: relative;
    padding: 0.35rem 0 0.35rem 1.5rem;
    color: var(--charleston-slate);
}

.prose ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 1.05rem;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--charleston-gold);
}


.page-cta {
    text-align: center;
    padding: 0 0 100px;
}

@media (max-width: 768px) {
    .page-hero {
        padding: 140px 0 60px;
    }

    .page-hero .section-title {
        font-size: 2.25rem;
    }

    .prose h2 {
        font-size: 1.6rem;
    }
}

/* ---- Footer contact / NAP ---- */
footer p + p {
    margin-top: 0.4rem;
    font-size: 0.9rem;
    opacity: 0.75;
}

footer a {
    color: var(--charleston-cream);
    text-decoration: none;
    border-bottom: 1px solid rgba(254, 252, 248, 0.3);
    transition: border-color 0.3s ease;
}

footer a:hover {
    border-bottom-color: var(--charleston-gold);
}
