/* ======= Theme (Adobe palette + Eras Demi ITC) ======= */
@font-face{
  font-family:'ErasDemiITC';
  src: url('assets/fonts/eras/ErasDemiITC.woff2') format('woff2'),
       url('assets/fonts/eras/ErasDemiITC.woff') format('woff');
  font-weight:600; font-style:normal; font-display:swap;
}

:root{
  --bg:#FFFFFF;
  --text:#333333;
  --muted:#6b7280;
  --border:#e5e7eb;

  --accent:#3E7BA3;   /* steel blue */
  --accent-2:#7C328C; /* deep purple */
  --accent-3:#E89EDA; /* pink */
  --tint:#BEDDFF;     /* sky */

  --card:#fafafa;
  --radius:14px;
  --shadow:0 8px 24px rgba(0,0,0,.06);
  --maxw:1200px;
}

*{box-sizing:border-box}
html,body{margin:0}
body{
  font-family:'ErasDemiITC', Arial, sans-serif;
  background:var(--bg); color:var(--text); line-height:1.6;
}
img{max-width:100%; display:block}

/* ===== Containers ===== */
.container{max-width:var(--maxw); margin:0 auto; padding:0 20px}

/* ===== Header (old-site blue band, centered) ===== */
header{
  position:sticky; top:0; z-index:30;
  background: var(--accent);
  border-bottom:none;
}
header .container{max-width:1280px; margin:0 auto}
header .brand{
  width:100%; display:flex; flex-direction:column; align-items:center; gap:6px;
  padding:18px 0 8px;
}
header .brand h1{
  letter-spacing:.5px; font-weight:600; color:#ecf3f8;
  text-shadow:0 1px 0 rgba(0,0,0,.35);
  font-size:34px; margin:0; text-align:center;
}
nav{width:100%; display:flex; justify-content:center; gap:28px; padding:0 0 10px}
nav a{color:#e8eef5; opacity:.95; text-decoration:none; font-weight:600; letter-spacing:.6px}
nav a:hover{opacity:1; text-decoration:underline; text-underline-offset:4px}
nav a.active{text-decoration:underline; text-underline-offset:6px}

/* ===== Hero (general utility; homepage has inline CSS too) ===== */
.hero{max-width:var(--maxw); margin:40px auto; padding:0 20px}
.hero h2{font-size:40px; color:var(--accent-2); margin:0 0 8px}
.hero p{font-size:18px; color:var(--muted); margin:0}
.cta-row{display:flex; gap:12px; margin-top:18px}
.btn{
  padding:10px 14px; border-radius:10px; border:1px solid var(--border);
  background:#fff; color:var(--text); text-decoration:none; font-weight:500
}
.btn.primary{background:var(--accent); border-color:var(--accent); color:#fff}
.btn.ghost{background:transparent; border-color:var(--accent-2); color:var(--accent-2)}
.btn:hover{box-shadow:var(--shadow)}

/* ===== Grid / Cards ===== */
.grid{
  display:grid; grid-template-columns:repeat(auto-fill,minmax(280px,1fr));
  gap:42px 46px; padding:36px 20px 60px;
}
.card{
  background:transparent; border:none; border-radius:0; box-shadow:none; cursor:pointer
}
.card:hover{transform:none; box-shadow:none}
.card img{
  width:100%; aspect-ratio:16/9; object-fit:contain;
  background:#111; border-radius:4px;
}
.card .content{padding:10px 4px 0; text-align:center}
.card h3{color:var(--accent); font-size:16px; margin:0}
.card .meta, .card p{display:none}

/* ===== Modal (dark) ===== */
.modal{
  position:fixed; inset:0; background:rgba(0,0,0,0.75);
  display:none; align-items:center; justify-content:center; padding:20px; z-index:1000
}
.modal.show{display:flex}
.modal .modal-content{
  background:#0f1115; color:#e7eaee; border-radius:var(--radius);
  max-width:960px; width:100%; padding:10px; position:relative; box-shadow:var(--shadow)
}
.modal .close{
  position:absolute; top:10px; right:10px; border:1px solid var(--border);
  border-radius:50%; width:32px; height:32px; cursor:pointer; background:#111; color:#fff
}
#playerContainer iframe, #playerContainer video{
  width:100%; height:54vh; border:0; border-radius:10px; background:#000
}
#meta{padding:10px 4px 12px; color:#cfd3d7; font-size:14px}

/* ===== Footer (dark) ===== */
footer{
  padding:26px 20px; border-top:1px solid rgba(255,255,255,0.06);
  margin-top:40px; text-align:center; color:#9aa3ab; font-size:14px
}

/* ===== Back-to-top button ===== */
#toTop{
  position:fixed; right:18px; bottom:18px; z-index:40;
  width:44px; height:44px; border-radius:50%;
  background: rgba(62,123,163,0.95); color:#fff; border:none;
  display:flex; align-items:center; justify-content:center; cursor:pointer;
  box-shadow:0 6px 16px rgba(0,0,0,0.3);
}
#toTop:hover{filter:brightness(1.05)}

/* ---------- Wiggle text effect ---------- */
.page-title{ text-align:center; margin:28px 0 10px; letter-spacing:.06em; color:#e8eef5; }

.wiggle span{
  display:inline-block;
  transform-origin:50% 60%;
  animation: wiggle 2.2s ease-in-out infinite;
  animation-delay: calc(var(--i) * 60ms);
}

.wiggle.glow span{
  text-shadow:0 0 0 rgba(255,255,255,0);
  animation-name: wiggle, glow;
  animation-duration: 2.2s, 3.4s;
  animation-timing-function: ease-in-out, ease-in-out;
  animation-iteration-count: infinite, infinite;
  animation-delay: calc(var(--i) * 60ms), calc(var(--i) * 60ms);
}

@keyframes wiggle{
  0%,100%{ transform: translateY(0) rotate(0deg); }
  20%    { transform: translateY(-1px) rotate(-0.6deg); }
  40%    { transform: translateY( 1px) rotate( 0.6deg); }
  60%    { transform: translateY(-0.5px) rotate(-0.4deg); }
  80%    { transform: translateY( 0.5px) rotate( 0.4deg); }
}

@keyframes glow{
  0%,100%{ text-shadow: 0 0 0 rgba(255,255,255,0); }
  50%    { text-shadow: 0 0 10px rgba(255,255,255,0.08); }
}

@media (prefers-reduced-motion: reduce){
  .wiggle span{ animation: none !important; }
}
