/* ========== CUSTOM FONTS ========== */
@font-face {
    font-family: 'RealityStone';
    src: url('fonts/Reality Stone.ttf') format('truetype');
    font-weight: normal;
    font-style: normal;
}

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

/* ========== SEA HARVEST COLOR SYSTEM ========== */
:root {
    --color-primary: #231f20;
    --color-accent: #26498d;
    --color-light: #fff;
    --color-cream: #fffcf9;
    --color-black: #000;

    --text-primary: #231f20;
    --text-accent: #26498d;
    --bg-primary: #fffcf9;
    --bg-secondary: #231f20;
}

/* ========== TYPOGRAPHY ========== */
html {
    background: var(--bg-primary);
    overflow-x: hidden;
}

body {
    font-family: 'Courier New', Courier, monospace;
    font-size: 14px;
    line-height: 1.71428571;
    color: var(--text-primary);
    background: var(--color-light);
    -webkit-font-smoothing: antialiased;
    max-width: 1400px;
    overflow-x: hidden;
    margin: 1rem auto;
    padding: 0;
    box-shadow: 0 0 0 2px var(--color-primary), inset 0 0 0 2px var(--color-primary);
    min-height: calc(100vh - 2rem);
    position: relative;
}

@media screen and (min-width: 700px) {
    body {
        font-size: 1.2857142857142858rem;
        line-height: 1.66666667;
    }
}

h1, h2, h3, h4, h5, h6, .title {
    font-family: Georgia, serif;
    font-weight: 700;
    text-transform: uppercase;
    margin: 0;
    line-height: 0.891;
}

.title {
    font-size: 3rem;
    line-height: 0.85714286;
}

@media screen and (min-width: 700px) {
    .title {
        font-size: 5.714285714285714rem;
        line-height: 1;
    }
}

.title--masthead {
    font-size: 3rem;
    line-height: 1;
    text-align: center;
}

@media screen and (min-width: 700px) {
    .title--masthead {
        font-size: 6.571428571428571rem;
        line-height: 1;
    }
}

.title--medium {
    font-size: 2.5rem;
    line-height: 0.85714286;
}

@media screen and (min-width: 700px) {
    .title--medium {
        font-size: 4.857142857142857rem;
        line-height: 1;
    }
}

/* Narrow card title overrides — col-sm-3 cards can't hold large title--medium */
[data-editable-id="project3-title"],
[data-editable-id="project4-title"] {
    font-size: 1.6rem;
    line-height: 1.1;
}

@media screen and (min-width: 700px) {
    [data-editable-id="project3-title"],
    [data-editable-id="project4-title"] {
        font-size: 2rem;
        line-height: 1.1;
    }
}

.title--ad {
    font-size: 2rem;
    text-align: center;
    margin-bottom: 1rem;
    line-height: 1;
}

@media screen and (min-width: 700px) {
    .title--ad {
        font-size: 3.357142857142857rem;
    }
}

.title-description {
    font-family: 'Courier New', Courier, monospace;
    font-size: 1rem;
    line-height: 1.71428571;
    text-transform: uppercase;
    font-weight: 400;
    color: var(--text-primary);
    opacity: 0.7;
    margin: 0;
}

@media screen and (min-width: 700px) {
    .title-description {
        font-size: 1.1428571428571428rem;
        line-height: 1.5;
    }
}

p {
    margin-bottom: 1rem;
}

h1 {
    font-size: 3.5rem;
    line-height: 0.85714286;
}

h2 {
    font-size: 2.8rem;
    line-height: 0.891;
}

h3 {
    font-size: 2.2857rem;
    line-height: 1;
}

h4 {
    font-size: 1.857rem;
    line-height: 1.15;
}

/* ========== LAYOUT SYSTEM ========== */
.border {
    box-shadow: 0 0 0 1px var(--color-primary), inset 0 0 0 1px var(--color-primary);
}

.component {
    display: flex;
    flex-direction: column;
    position: relative;
}

.component-header, .component-footer {
    flex: 0 1 auto;
}

.component-body {
    flex: 1 0 0;
    height: auto;
    width: auto;
}

.row {
    display: flex;
    flex-wrap: wrap;
    margin: 0;
    border: 2px solid var(--color-primary);
    border-top: none;
}

/* 12-column grid system */
.col-12 { flex: 0 0 100%; max-width: 100%; width: 100%; }
.col-11 { flex: 0 0 91.66666667%; max-width: 91.66666667%; width: 91.66666667%; }
.col-10 { flex: 0 0 83.33333333%; max-width: 83.33333333%; width: 83.33333333%; }
.col-9 { flex: 0 0 75%; max-width: 75%; width: 75%; }
.col-8 { flex: 0 0 66.66666667%; max-width: 66.66666667%; width: 66.66666667%; }
.col-7 { flex: 0 0 58.33333333%; max-width: 58.33333333%; width: 58.33333333%; }
.col-6 { flex: 0 0 50%; max-width: 50%; width: 50%; }
.col-5 { flex: 0 0 41.66666667%; max-width: 41.66666667%; width: 41.66666667%; }
.col-4 { flex: 0 0 33.33333333%; max-width: 33.33333333%; width: 33.33333333%; }
.col-3 { flex: 0 0 25%; max-width: 25%; width: 25%; }
.col-2 { flex: 0 0 16.66666667%; max-width: 16.66666667%; width: 16.66666667%; }
.col-1 { flex: 0 0 8.33333333%; max-width: 8.33333333%; width: 8.33333333%; }

/* Responsive breakpoints - Sea Harvest uses 700px */
@media screen and (min-width: 700px) {
    .col-sm-12 { flex: 0 0 100%; max-width: 100%; width: 100%; }
    .col-sm-11 { flex: 0 0 91.66666667%; max-width: 91.66666667%; width: 91.66666667%; }
    .col-sm-10 { flex: 0 0 83.33333333%; max-width: 83.33333333%; width: 83.33333333%; }
    .col-sm-9 { flex: 0 0 75%; max-width: 75%; width: 75%; }
    .col-sm-8 { flex: 0 0 66.66666667%; max-width: 66.66666667%; width: 66.66666667%; }
    .col-sm-7 { flex: 0 0 58.33333333%; max-width: 58.33333333%; width: 58.33333333%; }
    .col-sm-6 { flex: 0 0 50%; max-width: 50%; width: 50%; }
    .col-sm-5 { flex: 0 0 41.66666667%; max-width: 41.66666667%; width: 41.66666667%; }
    .col-sm-4 { flex: 0 0 33.33333333%; max-width: 33.33333333%; width: 33.33333333%; }
    .col-sm-3 { flex: 0 0 25%; max-width: 25%; width: 25%; }
    .col-sm-2 { flex: 0 0 16.66666667%; max-width: 16.66666667%; width: 16.66666667%; }
    .col-sm-1 { flex: 0 0 8.33333333%; max-width: 8.33333333%; width: 8.33333333%; }

    .row--extend-bottom { padding-bottom: 7.14285714rem; }
}

@media screen and (min-width: 1060px) {
    .col-md-4 { flex: 0 0 33.33333333%; max-width: 33.33333333%; width: 33.33333333%; }
}

/* ========== HEADER ========== */
.header-banner {
    padding: 2rem 1rem;
    border: 2px solid var(--color-primary);
    text-align: center;
    margin-bottom: 0;
}

.site-title {
    font-family: 'RealityStone', Georgia, serif;
    font-size: 3.5rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    margin: 1rem 0;
}

.site-description {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    opacity: 0.8;
}

.date {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    opacity: 0.6;
    margin-bottom: 2rem;
}

/* ========== FOOTER ========== */
.site-footer {
    text-align: center;
    padding: 1.5rem 1rem;
    border-top: 2px solid var(--color-primary);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    opacity: 0.6;
    margin-top: 2rem;
}

/* ========== NAVIGATION ========== */
.under-construction {
    border: 2px solid var(--color-primary);
    border-top: none;
    background: var(--color-light);
    color: var(--text-secondary);
    font-size: 0.85rem;
    text-align: center;
    padding: 0.5rem 1rem;
    margin: 0;
}

/* ========== CARDS ========== */
.card {
    background: var(--color-light);
    margin-bottom: -2px;
    box-shadow: 0 0 0 2px var(--color-primary), inset 0 0 0 2px var(--color-primary);
    padding: 1.5rem;
    font-weight: 400;
    min-height: 250px;
    transition: color 0.2s ease;
}

@media screen and (min-width: 700px) {
    .card {
        padding: 2rem;
        min-height: 300px;
    }
}

.card:hover,
.card:hover * {
    color: var(--color-accent) !important;
}


.article--card {
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}

.article--card .component-header {
    margin-bottom: 26px;
}

.article--card .card-thumb {
    margin-bottom: 30px;
}

[data-media-id="project1-img"] {
    height: 500px;
    overflow: hidden;
}

[data-media-id="project1-img"] img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top;
    display: block;
}

.article--card .image,
.card .image {
    width: 100%;
    height: auto;
    display: block;
    margin-bottom: 2rem;
    object-fit: contain;
}

@media screen and (min-width: 700px) {
    .article--card .image,
    .card .image {
        min-height: unset;
    }
}

.copy--card {
    font-size: 1.1rem;
    line-height: 1.7;
}

@media screen and (min-width: 700px) {
    .copy--card {
        font-size: 1.3rem;
        line-height: 1.8;
    }
}

/* Squat cards (wide and short) need tighter typography */
.card[style*="min-height: 180px"] .copy--card,
.card[style*="min-height: 200px"] .copy--card,
.card[style*="min-height: 220px"] .copy--card,
.card[style*="min-height: 240px"] .copy--card {
    font-size: 0.95rem;
    line-height: 1.5;
}

@media screen and (min-width: 700px) {
    .card[style*="min-height: 180px"] .copy--card,
    .card[style*="min-height: 200px"] .copy--card,
    .card[style*="min-height: 220px"] .copy--card,
    .card[style*="min-height: 240px"] .copy--card {
        font-size: 1.1rem;
        line-height: 1.6;
    }
}

.card[style*="min-height: 180px"] .title,
.card[style*="min-height: 200px"] .title,
.card[style*="min-height: 220px"] .title,
.card[style*="min-height: 240px"] .title {
    font-size: 1.8rem;
    line-height: 1;
}

@media screen and (min-width: 700px) {
    .card[style*="min-height: 180px"] .title,
    .card[style*="min-height: 200px"] .title,
    .card[style*="min-height: 220px"] .title,
    .card[style*="min-height: 240px"] .title {
        font-size: 2.5rem;
        line-height: 1;
    }
}

.article-number {
    font-size: 0.75rem;
    font-style: italic;
    opacity: 0.7;
}

/* Ad cards */
.card.ad .card-special-border {
    border: 2px solid var(--color-primary);
    padding: 2rem 1.5rem;
}

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

.get-in-touch {
    text-align: center;
}

.get-in-touch .image {
    max-width: 120px;
    margin: 0 auto 1rem;
}

.location {
    margin: 1.5rem 0;
    padding: 1rem 0;
    border-top: 1px solid rgba(35, 31, 32, 0.2);
}

.location:first-child {
    border-top: none;
}

.section-heading {
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.section-text {
    font-size: 0.9rem;
    line-height: 1.5;
    margin-bottom: 0.25rem;
}

.link--inline {
    color: var(--text-accent);
    text-decoration: none;
    border-bottom: 1px solid var(--text-accent);
}

.link--inline:hover {
    opacity: 0.7;
}

/* ========== CONTAINER ========== */
.container {
    max-width: 100%;
    margin: 0 auto;
    padding: 0;
}

/* ========== MODAL ========== */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    overflow-y: auto;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: var(--bg-primary);
    margin: 5% auto;
    padding: 3rem;
    max-width: 900px;
    position: relative;
    box-shadow: 0 0 0 1px var(--color-primary), inset 0 0 0 1px var(--color-primary);
}

.close {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    font-size: 2rem;
    font-weight: 400;
    line-height: 1;
    color: var(--text-primary);
    cursor: pointer;
    transition: opacity 0.2s;
}

.close:hover {
    opacity: 0.5;
}

.modal-content h2 {
    margin-bottom: 1.5rem;
}

.modal-content p {
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 1.5rem;
}

.modal-media-stack {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    margin-top: 2rem;
}

.modal-media-block {
    width: 100%;
    min-height: 200px;
    background: rgba(0, 0, 0, 0.03);
    border: 2px dashed rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(0, 0, 0, 0.3);
    font-size: 0.85rem;
    overflow: hidden;
}

.modal-media-block img {
    width: 100%;
    height: auto;
    display: block;
}

.modal-media-block .youtube-container {
    width: 100%;
}

/* ========== EDIT MODE STYLES ========== */
.edit-mode-active [data-editable-id],
.edit-mode-active [data-media-id] {
    outline: 2px dashed rgba(0, 102, 204, 0.3);
    outline-offset: 2px;
    cursor: pointer;
    transition: outline 0.2s, background 0.2s;
}

.edit-mode-active [data-editable-id]:hover,
.edit-mode-active [data-media-id]:hover {
    outline: 2px solid rgba(0, 102, 204, 0.6);
    background: rgba(0, 102, 204, 0.05);
}

/* Prevent iframes and images from capturing clicks in edit mode */
.edit-mode-active [data-media-id] iframe,
.edit-mode-active [data-media-id] img {
    pointer-events: none;
}

[data-editable-id].editing {
    outline: 2px solid #0066cc !important;
    background: rgba(0, 102, 204, 0.1) !important;
}

.edit-mode-indicator {
    position: fixed;
    top: 20px;
    right: 20px;
    background: rgba(0, 102, 204, 0.4);
    color: white;
    padding: 6px 12px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 400;
    z-index: 10000;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
    animation: slideIn 0.3s;
}

@keyframes slideIn {
    from { transform: translateX(100px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

.save-notification {
    position: fixed;
    top: 55px;
    right: 20px;
    background: rgba(40, 167, 69, 0.5);
    color: white;
    padding: 6px 12px;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 400;
    z-index: 10000;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
    animation: slideIn 0.3s;
}

.save-notification.error {
    background: rgba(220, 53, 69, 0.5);
}

/* ========== BRAND SECTIONS (modal) ========== */
.brand-section {
    margin: 2.5rem 0;
    border-top: 1px solid var(--color-primary);
    padding-top: 1.5rem;
}

.brand-section-heading {
    font-family: Georgia, serif;
    font-size: 1.3rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 1rem;
}

.mosaic {
    display: grid;
    grid-template-columns: 2fr 1fr;
    grid-template-rows: auto auto;
    gap: 4px;
    margin-bottom: 1rem;
}

.mosaic-cell {
    position: relative;
    background: var(--color-cream, #f5f0e8);
    border: 1px dashed var(--color-primary);
    min-height: 160px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.mosaic-cell--hero {
    grid-row: 1 / 3;
    min-height: 324px;
}

.mosaic-cell img {
    width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
}

.mosaic-cell-caption {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(0, 0, 0, 0.55);
    color: #fff;
    font-family: 'Courier New', monospace;
    font-size: 0.65rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 0.3rem 0.6rem;
    margin: 0;
    line-height: 1.4;
    z-index: 1;
}

.mosaic-label {
    font-family: 'Courier New', monospace;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    opacity: 0.4;
    position: absolute;
    bottom: 0.5rem;
    left: 0.75rem;
    pointer-events: none;
}

.mosaic-cell:has(img) .mosaic-label {
    display: none;
}

.brand-section-caption {
    font-size: 1rem;
    line-height: 1.6;
    opacity: 0.8;
    margin-top: 0.5rem;
}

/* ========== PDF EMBED ========== */
.pdf-embed {
    display: block;
    width: 100%;
    height: 80vh;
    border: 1px solid var(--color-primary);
    margin-top: 1.5rem;
}

/* ========== LOGO GRID ========== */
.logo-grid {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding: 2rem 0;
}

.logo-grid img {
    flex: 1;
    max-height: 48px;
    width: auto;
    object-fit: contain;
}

/* ========== YOUTUBE EMBEDS ========== */
.youtube-container {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 aspect ratio */
    height: 0;
    overflow: hidden;
    background: #000;
    margin-bottom: 2rem;
}

/* Inside mosaic cells, fill the cell without margin blowout */
.mosaic-cell .youtube-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    padding-bottom: 0;
    margin-bottom: 0;
}

.youtube-container iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

.youtube-facade {
    cursor: pointer;
}

.youtube-facade-thumb {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.youtube-play-btn {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 56px;
    height: 56px;
    background: rgba(0, 0, 0, 0.65);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.2rem;
    pointer-events: none;
    transition: background 0.2s;
    padding-left: 4px;
}

.youtube-facade:hover .youtube-play-btn {
    background: rgba(200, 0, 0, 0.85);
}

.local-video {
    width: 100%;
    height: auto;
    display: block;
}

.youtube-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    background: rgba(0, 0, 0, 0.05);
    border: 2px dashed rgba(0, 0, 0, 0.2);
    color: rgba(0, 0, 0, 0.4);
    font-size: 0.9rem;
    text-align: center;
    padding: 1rem;
}

/* ========== LIGHTBOX ========== */
#lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    z-index: 20000;
    overflow-y: auto;
    cursor: zoom-out;
}

#lightbox.open {
    display: flex;
    align-items: flex-start;
    justify-content: center;
    padding: 40px 20px;
}

.lightbox-inner {
    position: relative;
    cursor: default;
    max-width: 1400px;
    width: 100%;
}

#lightbox-img {
    display: block;
    width: 100%;
    height: auto;
    border-radius: 2px;
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.6);
}

.lightbox-close {
    position: fixed;
    top: 16px;
    right: 20px;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.7);
    font-size: 2.5rem;
    line-height: 1;
    cursor: pointer;
    z-index: 20001;
    padding: 0 6px;
}

.lightbox-close:hover {
    color: #fff;
}

/* Make images inside media boxes show a zoom cursor in normal mode */
[data-media-id] img {
    cursor: zoom-in;
}
