/* page: videos */

/* page: videos — page-specific styles only */

/* page: videos — extracted from videos.html; keep page-specific rules only */

/* ── Design tokens ───────────────────────────────────────────────────── */
:root {
    --teal:              #00A896;
    --teal-dark:         #088F7F;
    --burnt-orange:      #DD6F3E;
    --burnt-orange-dark: #C45E32;
    --deep-brown:        #3D2321;
    --sand-50:           #FDFAF4;
    --sand-200:          #F3E9D2;
    --ease-out-expo:     ease;
    --copper-bg:    #E8D5B7;
    --copper-mid:   #D4B896;
    --copper-dark:  #B8956A;
    --copper-deep:  #8B6914;
    --accent:       #C5A059;
    --paper:        #fdfaf3;
    --shadow:       rgba(61,35,33,0.18);
    --ease:         ease;
    --lj-earth:     #3D2321;
    --lj-paper:     #F2EFE9;
    --lj-accent:    #C5A059;
    --lj-ink-light: rgba(61,35,33,0.6);
    --font-footer:  'Lato', sans-serif;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
    background: linear-gradient(180deg, var(--sand-50) 0%, var(--sand-200) 30%, #C4A77D 70%, #8B7355 100%);
    color: var(--deep-brown);
    font-family: 'Lato', sans-serif;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

/* Subtle topographic ripple pattern - different from team.html */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    background-image:
        repeating-radial-gradient(circle at 20% 30%, transparent 0, transparent 60px, rgba(61,35,33,0.025) 61px, transparent 62px),
        repeating-radial-gradient(circle at 80% 60%, transparent 0, transparent 80px, rgba(61,35,33,0.02) 81px, transparent 82px),
        repeating-radial-gradient(circle at 40% 90%, transparent 0, transparent 70px, rgba(61,35,33,0.03) 71px, transparent 72px);
}

/* ── Page hero ───────────────────────────────────────────────────────── */
.page-hero {
    padding: 140px 5% 40px;
    text-align: center;
    position: relative;
    z-index: 1;
}

.page-hero h1 { font-family: 'Playfair Display', serif; font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 400; color: var(--deep-brown); letter-spacing: -0.02em; line-height: 1.15; margin-bottom: 0.6rem; }

.page-hero h1 em { color: var(--copper-deep); font-style: italic; }

.page-hero p { font-size: 0.95rem; color: rgba(61,35,33,0.6); letter-spacing: 0.06em; text-transform: uppercase; }

/* ── Netflix-style Video Rows ─────────────────────────────────────────── */
.video-section {
    padding: 2rem 0 3rem;
    position: relative;
    z-index: 1;
}

.video-row {
    margin-bottom: 3rem;
    padding: 0 5%;
}

.video-row-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.video-row-title {
    font-family: 'Playfair Display', serif;
    font-size: clamp(1.3rem, 2.5vw, 1.8rem);
    font-weight: 600;
    color: var(--deep-brown);
    letter-spacing: -0.01em;
}

.video-row-title i {
    color: var(--burnt-orange);
    margin-right: 0.5rem;
    font-size: 0.9em;
}

.video-row-scroll {
    display: flex;
    gap: 1.2rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 1rem 0 2rem;
    margin: 0 -5%;
    padding-left: 5%;
    padding-right: 5%;
    -webkit-overflow-scrolling: touch;
}

.video-row-scroll::-webkit-scrollbar {
    height: 6px;
}

.video-row-scroll::-webkit-scrollbar-track {
    background: rgba(61,35,33,0.1);
    border-radius: 3px;
}

.video-row-scroll::-webkit-scrollbar-thumb {
    background: var(--burnt-orange);
    border-radius: 3px;
}

/* Netflix-style video card */
.video-card {
    flex: 0 0 auto;
    width: clamp(280px, 30vw, 380px);
    scroll-snap-align: start;
    background: rgba(255,255,255,0.95);
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.4s var(--ease), box-shadow 0.4s var(--ease);
    box-shadow: 0 8px 30px rgba(61,35,33,0.12);
    border: 1px solid rgba(184,149,106,0.2);
}

.video-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 50px rgba(61,35,33,0.2);
}

.video-card-thumb {
    position: relative;
    height: 200px;
    background: linear-gradient(135deg, #2a1f1a 0%, #3d2b1f 100%);
    overflow: hidden;
}

.video-card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s var(--ease);
}

.video-card:hover .video-card-thumb img {
    transform: scale(1.08);
}

.video-card-play {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.3);
    transition: background 0.3s;
}

.video-card:hover .video-card-play {
    background: rgba(0,0,0,0.45);
}

.video-card-play-btn {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: rgba(255,255,255,0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 30px rgba(0,0,0,0.4);
    transition: transform 0.3s var(--ease), background 0.3s;
}

.video-card:hover .video-card-play-btn {
    transform: scale(1.12);
    background: white;
}

.video-card-play-btn i {
    color: var(--deep-brown);
    font-size: 1.3rem;
    margin-left: 4px;
}

.video-card-duration {
    position: absolute;
    bottom: 10px;
    right: 12px;
    background: rgba(0,0,0,0.8);
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 4px;
    letter-spacing: 0.03em;
}

.video-card-info {
    padding: 1.2rem 1.4rem 1.4rem;
}

.video-card-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--deep-brown);
    line-height: 1.35;
    margin-bottom: 0.5rem;
}

.video-card-desc {
    font-size: 0.85rem;
    color: rgba(61,35,33,0.65);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.video-card-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-top: 0.8rem;
    padding-top: 0.8rem;
    border-top: 1px solid rgba(184,149,106,0.2);
    font-size: 0.75rem;
    color: var(--burnt-orange);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.video-card-meta i {
    font-size: 0.85rem;
}

/* Scroll navigation arrows */
.scroll-nav {
    display: flex;
    gap: 0.5rem;
}

.scroll-nav button {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(61,35,33,0.2);
    background: rgba(255,255,255,0.8);
    color: var(--deep-brown);
    cursor: pointer;
    transition: background .25s ease, color .25s ease, box-shadow .25s ease, transform .25s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.scroll-nav button:hover {
    background: var(--burnt-orange);
    border-color: var(--burnt-orange);
    color: white;
}

/* Grid layout for All Videos (not horizontal scroll) */
.video-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
    padding: 1rem 0 3rem;
}

.video-grid .video-card {
    width: 100%;
}

@media (max-width: 768px) {
  .video-grid {
        grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
        gap: 1.5rem;
    }
}

@media (max-width: 480px) {
  .video-grid {
        grid-template-columns: 1fr;
    }
}

/* Legacy grid for fallback */
.lib-grid {
    display: none;
}

.lib-card {
    background: rgba(255,252,245,0.9);
    border: 1px solid rgba(184,149,106,0.3);
    border-radius: 14px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), border-color 0.3s;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 16px rgba(61,35,33,0.08);
}

.lib-card:hover { transform: translateY(-7px); box-shadow: 0 20px 50px rgba(61,35,33,0.16); border-color: var(--accent); }

/* Video thumbnail cover */
.vid-cover {
    height: 200px;
    background: linear-gradient(135deg, #2a1f1a 0%, #3d2b1f 100%);
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

.vid-cover img {
    width: 100%; height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s var(--ease);
}

.lib-card:hover .vid-cover img { transform: scale(1.05); }

.vid-cover-placeholder {
    width: 100%; height: 100%;
    display: flex; align-items: center; justify-content: center;
    font-size: 3rem; opacity: 0.4; color: var(--accent);
}

.play-overlay {
    position: absolute; inset: 0;
    display: flex; align-items: center; justify-content: center;
    background: rgba(0,0,0,0.25);
    transition: background 0.2s;
}

.lib-card:hover .play-overlay { background: rgba(0,0,0,0.4); }

.play-btn-circle {
    width: 56px; height: 56px;
    border-radius: 50%;
    background: rgba(255,255,255,0.92);
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
    transition: transform 0.25s var(--ease), background 0.2s;
}

.lib-card:hover .play-btn-circle { transform: scale(1.15); background: white; }

.play-btn-circle i { color: var(--deep-brown); font-size: 1.1rem; margin-left: 3px; }

.vid-duration {
    position: absolute; bottom: 8px; right: 10px;
    background: rgba(0,0,0,0.7);
    color: #fff; font-size: 0.7rem; font-weight: 700;
    padding: 2px 7px; border-radius: 4px; letter-spacing: 0.04em;
}

.lib-card-body { padding: 1rem 1.2rem 1.3rem; flex: 1; display: flex; flex-direction: column; gap: 0.35rem; }

.lib-card-title { font-family: 'Playfair Display', serif; font-size: 1rem; font-weight: 700; color: var(--deep-brown); line-height: 1.35; }

.lib-card-desc { font-size: 0.78rem; color: rgba(61,35,33,0.6); line-height: 1.5; margin-top: 0.2rem; }

.lib-card-btn {
    margin-top: auto; padding-top: 0.8rem;
    background: var(--deep-brown); color: var(--copper-bg);
    border: none; border-radius: 7px;
    padding: 0.6rem 1rem;
    font-family: 'Lato', sans-serif; font-size: 0.76rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.12em;
    cursor: pointer; transition: background 0.2s;
    width: 100%;
}

.lib-card-btn:hover { background: var(--burnt-orange); }

.lib-empty {
    grid-column: 1/-1; text-align: center;
    padding: 5rem 2rem; color: rgba(61,35,33,0.5);
}

.lib-empty h3 { font-family: 'Playfair Display', serif; font-size: 1.5rem; margin-bottom: 0.75rem; color: var(--deep-brown); }

.lib-empty p { font-size: 0.88rem; }

/* ── Video modal ─────────────────────────────────────────────────────── */
.video-modal-overlay {
    position: fixed; inset: 0;
    background: rgba(0,0,0,0.9);
    display: none; align-items: center; justify-content: center;
    z-index: 9000;
    padding: 1rem;
}

.video-modal-overlay.open { display: flex; }

.video-modal-inner {
    position: relative;
    width: 100%; max-width: 960px;
}

.video-modal-close {
    position: absolute; top: -44px; right: 0;
    background: none; border: none;
    color: rgba(255,255,255,0.8);
    font-size: 1.6rem; cursor: pointer;
    padding: 6px 12px;
    transition: color 0.2s;
    line-height: 1;
}

.video-modal-close:hover { color: #fff; }

.video-modal-title {
    position: absolute; top: -44px; left: 0;
    color: rgba(255,255,255,0.7);
    font-family: 'Playfair Display', serif;
    font-size: 0.95rem;
    white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    max-width: calc(100% - 60px);
    line-height: 2.5;
}

#videoPlayerWrap iframe,
#videoPlayerWrap video {
    width: 100%;
    aspect-ratio: 16/9;
    border: none;
    border-radius: 8px;
    display: block;
    background: #000;
}

.legal-links { display: flex; gap: 1.5rem; }

.legal-links a, .ddx-attr a { color: var(--lj-earth); text-decoration: none; font-weight: 700; }

.legal-links a:hover, .ddx-attr a:hover { text-decoration: underline; }

.giraffe { display: inline-block; transition: transform 0.3s; }

.ddx-attr:hover .giraffe { transform: translateY(-3px) scale(1.1); }

.stub-title { font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.15em; font-weight: 900; margin: 0 0 0.5rem; color: var(--lj-accent); }

.stub-heading { font-size: 1.5rem; font-weight: 300; margin: 0 0 1.5rem; line-height: 1.2; }

.stub-form { display: flex; flex-direction: column; gap: 1rem; }

.stub-form input { background: transparent; border: none; border-bottom: 2px solid rgba(61,35,33,0.2); padding: 0.5rem 0; font-family: var(--font-footer); font-size: 0.95rem; color: var(--lj-earth); outline: none; transition: border-color 0.3s; }

.stub-form input:focus { border-color: var(--lj-earth); }

.stub-form input::placeholder { color: var(--lj-ink-light); font-style: italic; }

.stub-form button { background-color: transparent; color: var(--lj-earth); border: 2px solid var(--lj-earth); padding: 0.6rem; border-radius: 6px; font-family: var(--font-footer); font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; cursor: pointer; transition: background .25s ease, color .25s ease, box-shadow .25s ease, transform .25s ease; }

.stub-form button:hover { background-color: var(--lj-earth); color: var(--lj-paper); }

.barcode { margin-top: 2rem; height: 30px; width: 100%; background: linear-gradient(90deg, var(--lj-earth) 0%, var(--lj-earth) 5%, transparent 5%, transparent 8%, var(--lj-earth) 8%, var(--lj-earth) 10%, transparent 10%, transparent 15%, var(--lj-earth) 15%, var(--lj-earth) 22%, transparent 22%, transparent 24%, var(--lj-earth) 24%, var(--lj-earth) 26%, transparent 26%, transparent 30%, var(--lj-earth) 30%, var(--lj-earth) 32%, transparent 32%, transparent 35%, var(--lj-earth) 35%, var(--lj-earth) 45%, transparent 45%, transparent 48%, var(--lj-earth) 48%, var(--lj-earth) 50%, transparent 50%, transparent 55%, var(--lj-earth) 55%, var(--lj-earth) 60%, transparent 60%, transparent 62%, var(--lj-earth) 62%, var(--lj-earth) 70%, transparent 70%, transparent 75%, var(--lj-earth) 75%, var(--lj-earth) 77%, transparent 77%, transparent 80%, var(--lj-earth) 80%, var(--lj-earth) 85%, transparent 85%, transparent 88%, var(--lj-earth) 88%, var(--lj-earth) 95%, transparent 95%, transparent 97%, var(--lj-earth) 97%, var(--lj-earth) 100%); opacity: 0.3; }

@media (max-width: 640px) {
  .lib-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 1rem; padding: 1rem 4% 3rem; }

  .vid-cover { height: 140px; }

  .play-btn-circle { width: 44px; height: 44px; }
}

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