/*
 * SOUTHERN CAL SEAFOOD, INC.
 * Ocean-inspired corporate website theme built from the official redesign plan.
 * Color palette: primary #1565C0, navy #0D47A1, seafoam #4DB6AC, sand #FFFDE7, coral #FF7043.
 */

:root {
    /* Brand Colors */
    --primary: #1565C0;
    --navy: #0D47A1;
    --seafoam: #4DB6AC;
    --sand: #FFFDE7;
    --coral: #FF7043;
    --ink: #1A237E;
    --text: #2C3E50;
    --muted: #546E7A;
    --border: #E2E8F0;
    --panel: #F5F7FA;
    --white: #FFFFFF;

    /* Typography */
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Roboto', sans-serif;
    --font-decor: 'Playfair Display', serif;
    --line-height: 1.7;

    /* Layout */
    --max-width: 1200px;
    --space-1: 8px;
    --space-2: 12px;
    --space-3: 16px;
    --space-4: 24px;
    --space-5: 32px;
    --space-6: 48px;
    --space-7: 64px;
    --space-8: 80px;

    /* Legacy alias variables (older page templates) */
    --spacing-sm: var(--space-2);
    --spacing-md: var(--space-3);
    --spacing-lg: var(--space-5);
    --spacing-xl: var(--space-7);
    --color-primary: var(--primary);
    --color-secondary: var(--coral);
    --color-accent: var(--seafoam);
    --color-text-dark: var(--text);
    --color-text-light: var(--white);
    --color-text-muted: var(--muted);
    --color-background-light: var(--panel);
    --color-background-dark: var(--navy);
    --color-border: var(--border);
    --border-radius: var(--radius-sm);

    /* Effects */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --shadow-soft: 0 12px 30px rgba(13, 71, 161, 0.08);
    --shadow-card: 0 16px 48px rgba(9, 30, 66, 0.12);
    --transition: 0.3s ease;
}

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

html {
    scroll-padding-top: 110px;
}

body {
    font-family: var(--font-body);
    color: var(--text);
    background-color: var(--panel);
    line-height: var(--line-height);
    min-height: 100vh;
}

.sr-only {
    position: absolute !important;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

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

a:hover {
    color: var(--seafoam);
}

.text-muted {
    color: var(--muted);
}

.bg-light {
    background: var(--color-background-light);
}

a:focus-visible {
    outline: 3px solid rgba(21, 101, 192, 0.25);
    outline-offset: 2px;
    border-radius: 4px;
}

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

ul {
    margin-left: var(--space-4);
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--ink);
    line-height: 1.25;
}

h1 { font-size: clamp(2.4rem, 4vw, 3.4rem); }
h2 { font-size: clamp(2rem, 3vw, 2.6rem); }
h3 { font-size: clamp(1.35rem, 2.4vw, 1.8rem); }
h4 { font-size: 1.2rem; }

main {
    padding-top: 90px; /* space for sticky header */
}

.container {
    width: 100%;
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 var(--space-4);
}

.section {
    padding: clamp(48px, 6vw, 96px) 0;
}

.p-xl {
    padding: var(--space-7) 0;
}

.section-heading {
    text-align: center;
    max-width: 760px;
    margin: 0 auto var(--space-5);
}

.section-heading p {
    color: var(--muted);
}

.eyebrow {
    display: inline-block;
    font-size: 0.85rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--seafoam);
    font-weight: 700;
    margin-bottom: var(--space-2);
}

.lead {
    font-size: 1.1rem;
    color: var(--muted);
}

.grid {
    display: grid;
    gap: var(--space-5);
    grid-template-columns: repeat(12, minmax(0, 1fr));
}

.grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.grid-4 {
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

.col-3 { grid-column: span 3; }
.col-4 { grid-column: span 4; }
.col-6 { grid-column: span 6; }
.col-8 { grid-column: span 8; }
.col-12 { grid-column: span 12; }

.split {
    display: grid;
    gap: var(--space-6);
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    align-items: center;
}

.card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: var(--space-5);
    box-shadow: var(--shadow-soft);
}

.card.bg-light {
    background: var(--color-background-light);
}

.muted-card {
    background: var(--sand);
    border-color: #F0E7C0;
}

.tag {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 999px;
    background: var(--seafoam);
    color: var(--white);
    font-size: 0.85rem;
    font-weight: 600;
}

.pill {
    display: inline-block;
    padding: 4px 10px;
    background: rgba(21, 101, 192, 0.08);
    color: var(--primary);
    border-radius: 999px;
    font-weight: 600;
    font-size: 0.85rem;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 18px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    letter-spacing: 0.02em;
    border: 2px solid transparent;
    cursor: pointer;
    transition: all var(--transition);
    text-transform: uppercase;
    font-family: var(--font-heading);
}

.btn:focus-visible {
    outline: 3px solid rgba(21, 101, 192, 0.25);
    outline-offset: 2px;
}

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

.btn-primary:hover { background: #0f4fa3; border-color: #0f4fa3; }

.btn-secondary {
    background: var(--seafoam);
    border-color: var(--seafoam);
    color: var(--white);
}

.btn-secondary:hover {
    background: #3EA99F;
    border-color: #3EA99F;
}

.btn-outline {
    background: transparent;
    border-color: var(--white);
    color: var(--white);
}

.btn-outline.dark {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background: rgba(255,255,255,0.12);
}

.btn-ghost {
    background: transparent;
    color: var(--primary);
    border-color: var(--border);
}

.btn-ghost:hover {
    border-color: var(--primary);
}

.btn-coral {
    background: var(--coral);
    border-color: var(--coral);
    color: var(--white);
}

/* Header & Navigation */
.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1200;
    background: var(--white);
    box-shadow: 0 8px 24px rgba(9, 30, 66, 0.12);
}

.nav-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-3);
    height: 84px;
    position: relative;
}
.site-header .container {
    padding-left: var(--space-1);
    padding-right: var(--space-3);
}

.logo {
    font-family: var(--font-heading);
    font-weight: 800;
    font-size: 1.4rem;
    color: var(--navy);
    letter-spacing: 0.03em;
}

.logo span {
    font-family: var(--font-decor);
    color: var(--seafoam);
}

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

.nav-menu > li {
    position: relative;
}

.nav-menu > li > a {
    display: block;
    padding: 12px 14px;
    color: var(--muted);
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: var(--radius-sm);
}

.nav-menu > li > a:hover {
    color: var(--primary);
    background: rgba(21, 101, 192, 0.08);
}

.nav-menu .has-dropdown > a::after {
    content: '▾';
    margin-left: 6px;
    font-size: 0.75rem;
}

.dropdown-menu {
    list-style: none;
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    min-width: 220px;
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-card);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: all var(--transition);
    padding: var(--space-2) 0;
    z-index: 20;
}

.nav-menu > li:hover > .dropdown-menu,
.nav-menu > li:focus-within > .dropdown-menu,
.dropdown-menu li:hover > .sub-dropdown-menu,
.dropdown-menu li:focus-within > .sub-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-menu li {
    position: relative;
}

.dropdown-menu a {
    display: block;
    padding: 10px var(--space-4);
    color: var(--muted);
}

.dropdown-menu a:hover {
    background: rgba(21, 101, 192, 0.06);
    color: var(--primary);
}

.sub-dropdown-menu {
    top: 0;
    left: 100%;
    border-radius: var(--radius-md);
}

.menu-toggle {
    display: none;
    background: none;
    border: 1px solid var(--border);
    padding: 10px;
    border-radius: var(--radius-sm);
    font-size: 1.1rem;
    color: var(--primary);
    cursor: pointer;
}

.menu-toggle:focus-visible {
    outline: 3px solid rgba(21, 101, 192, 0.25);
    outline-offset: 2px;
}

.nav-actions {
    display: none;
}

.nav-disclosure {
    display: flex;
    align-items: center;
    flex: 1 1 auto;
}

.nav-disclosure > summary {
    list-style: none;
}

.nav-disclosure > summary::-webkit-details-marker {
    display: none;
}

/* Desktop navigation sizing/nowrap */
@media (min-width: 1101px) {
    .nav-bar {
        flex-wrap: nowrap;
    }

    .logo {
        white-space: nowrap;
        font-size: 1.25rem;
    }

    .nav-menu {
        white-space: nowrap;
        gap: var(--space-1);
        flex-wrap: nowrap;
        justify-content: center;
    }

    .nav-menu > li > a {
        padding: 10px 12px;
    }

    .nav-actions {
        gap: var(--space-1);
        white-space: nowrap;
        flex-shrink: 0;
    }

    .nav-actions .btn {
        padding: 10px 14px;
        min-width: auto;
    }
}

/* Hero */
.hero {
    position: relative;
    min-height: 78vh;
    display: flex;
    align-items: center;
    color: var(--white);
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    /* Strictly follow redesign plan: no gradient overlays. */
    background-color: rgba(21, 101, 192, 0.6);
    z-index: 1;
}

.hero .container {
    position: relative;
    z-index: 2;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero h1 {
    color: var(--white);
    margin-bottom: var(--space-3);
}

.hero p {
    color: #E3ECFF;
    font-size: 1.1rem;
    max-width: 720px;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: var(--space-3);
    margin-top: var(--space-4);
}

.hero-metrics {
    margin-top: var(--space-6);
    display: grid;
    gap: var(--space-3);
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.metric {
    background: rgba(255, 255, 255, 0.14);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--radius-md);
    padding: var(--space-3);
}

.metric .number {
    font-size: 2rem;
    font-weight: 800;
}

.hero-small {
    min-height: 360px;
}

.hero-page {
    min-height: 40vh;
}

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

.section-header p {
    color: var(--muted);
}

/* Feature Blocks */
.product-card,
.service-card,
.news-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.product-card img,
.service-card img,
.news-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.product-card .content,
.service-card .content,
.news-card .content {
    padding: var(--space-5);
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: var(--space-3);
}

.product-card .tag,
.service-card .tag {
    align-self: flex-start;
}

.product-card .specs,
.service-card .specs {
    color: var(--muted);
    font-size: 0.95rem;
}

.service-card:hover,
.product-card:hover,
.news-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-card);
    transition: transform var(--transition), box-shadow var(--transition);
}

.badge-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: var(--space-3);
    margin-top: var(--space-4);
}

.badge {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: var(--space-4);
    text-align: center;
    box-shadow: var(--shadow-soft);
}

.badge .number {
    font-size: 2.2rem;
    font-weight: 800;
    color: var(--primary);
}

.highlight {
    background: var(--sand);
    border: 1px solid #F3E7B3;
    border-radius: var(--radius-lg);
    padding: var(--space-6);
}

.list-check {
    list-style: none;
    padding: 0;
    margin: 0;
    display: grid;
    gap: var(--space-2);
}

.list-check li {
    position: relative;
    padding-left: 26px;
    color: var(--muted);
}

.list-check li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--seafoam);
    font-weight: 800;
}

.stats-bar {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: var(--space-3);
    margin-top: var(--space-4);
}

.stat {
    padding: var(--space-4);
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    text-align: center;
}

.stat strong {
    display: block;
    font-size: 1.6rem;
    color: var(--primary);
}

.seasonal-banner {
    background: var(--seafoam);
    color: var(--white);
    border-radius: var(--radius-md);
    padding: var(--space-5);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-3);
    flex-wrap: wrap;
    box-shadow: var(--shadow-soft);
}

.quality-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-left: 4px solid var(--primary);
    border-radius: var(--radius-md);
    padding: var(--space-4);
    box-shadow: var(--shadow-soft);
}

.timeline {
    display: grid;
    gap: var(--space-4);
}

.timeline-item {
    display: grid;
    grid-template-columns: 120px 1fr;
    gap: var(--space-3);
    align-items: start;
}

.timeline-year {
    font-weight: 800;
    color: var(--primary);
}

.testimonial-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: var(--space-4);
    box-shadow: var(--shadow-soft);
}

.news-meta {
    font-size: 0.9rem;
    color: var(--muted);
}

.section-title {
    text-align: center;
    max-width: 760px;
    margin: 0 auto var(--space-6);
}

.section-title p {
    color: var(--muted);
}

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

.footer-links {
    list-style: none;
    padding-left: 0;
    margin-left: 0;
    display: grid;
    gap: var(--space-2);
}

.cta-section {
    background: var(--navy);
    color: var(--white);
    text-align: center;
    padding: var(--space-7) 0;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: var(--space-4);
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
}

th, td {
    padding: var(--space-3);
    border-bottom: 1px solid var(--border);
    text-align: left;
}

th {
    background: #E8F1FB;
    color: var(--ink);
    font-weight: 700;
}

tbody tr:nth-child(even) { background: rgba(21, 101, 192, 0.02); }

/* Forms */
form {
    display: grid;
    gap: var(--space-3);
}

label {
    font-weight: 700;
    color: var(--muted);
}

input, select, textarea {
    width: 100%;
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--white);
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color var(--transition), box-shadow var(--transition);
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(21, 101, 192, 0.15);
}

textarea { min-height: 140px; }

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: var(--space-3);
}

.contact-card {
    background: var(--white);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: var(--space-4);
    box-shadow: var(--shadow-soft);
}

.contact-card strong {
    display: block;
    color: var(--ink);
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: var(--space-3);
}

.gallery-grid img {
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-soft);
}

.faq-item {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: var(--space-4);
    background: var(--white);
}

.faq-item h4 {
    margin-bottom: var(--space-2);
}

.sitemap-list {
    columns: 2;
    column-gap: var(--space-6);
    list-style: none;
    padding: 0;
}

.sitemap-list li {
    margin-bottom: var(--space-2);
}

.prose > * + * {
    margin-top: var(--space-3);
}

.prose h2,
.prose h3 {
    margin-top: var(--space-5);
}

.prose ul,
.prose ol {
    margin-left: var(--space-4);
}

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

.rounded {
    border-radius: var(--radius-md);
}

.shadow {
    box-shadow: var(--shadow-soft);
}

.table-legend {
    display: flex;
    gap: var(--space-3);
    flex-wrap: wrap;
    align-items: center;
    color: var(--muted);
    font-size: 0.95rem;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--white);
}

.status-pill.available { background: var(--seafoam); }
.status-pill.limited { background: var(--coral); }
.status-pill.closed { background: #90A4AE; }

/* Footer */
footer {
    background: var(--navy);
    color: #DDE6FF;
    padding: var(--space-7) 0 var(--space-5);
    margin-top: var(--space-7);
}

footer h3 {
    color: var(--white);
}

footer a {
    color: #DDE6FF;
}

footer a:hover {
    color: var(--seafoam);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: var(--space-4);
}

.footer-bottom {
    text-align: center;
    margin-top: var(--space-5);
    padding-top: var(--space-3);
    border-top: 1px solid rgba(255,255,255,0.15);
    font-size: 0.95rem;
}

/* Accessibility */
.skip-link {
    position: absolute;
    left: -999px;
    top: -999px;
    padding: 10px 14px;
    background: var(--primary);
    color: var(--white);
    z-index: 2000;
}

.skip-link:focus {
    left: 20px;
    top: 20px;
}

/* Media Queries */
@media (min-width: 1101px) {
    /* Ensure the desktop navigation remains visible even when <details> is not open. */
    .nav-disclosure:not([open]) > nav {
        display: block;
    }
}

@media (max-width: 1100px) {
    .nav-menu {
        position: absolute;
        top: 84px;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        align-items: flex-start;
        padding: var(--space-4);
        border-bottom: 1px solid var(--border);
        display: none;
        box-shadow: var(--shadow-card);
    }

    .nav-disclosure[open] .nav-menu {
        display: flex;
    }

    .dropdown-menu,
    .sub-dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border: none;
        padding-left: var(--space-3);
        margin-top: var(--space-2);
    }

    .nav-bar {
        flex-wrap: wrap;
    }

    .nav-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .menu-toggle {
        display: inline-flex;
    }
}

@media (max-width: 768px) {
    .col-md-6 { grid-column: span 6; }
    .col-md-12 { grid-column: span 12; }

    .hero {
        min-height: 70vh;
    }

    .hero .container {
        padding-top: var(--space-6);
        padding-bottom: var(--space-6);
    }

    .timeline-item {
        grid-template-columns: 1fr;
    }

    .sitemap-list {
        columns: 1;
    }
}
