/**
 * Competition Recap — front-end styles
 * Palette mirrors the plugin's premium navy/gold system.
 */

.ecs-rc {
    --rc-navy:   #0c1f3f;
    --rc-navy-2: #12294f;
    --rc-gold:   #c9933a;
    --rc-gold-2: #e0b35f;
    --rc-ink:    #1d2433;
    --rc-muted:  #6b7280;
    --rc-line:   #e7e9ee;
    --rc-bg:     #f7f8fa;
    color: var(--rc-ink);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
}
.ecs-rc * { box-sizing: border-box; }
.ecs-rc-noscroll { overflow: hidden; }

/* Generic notice (gate states) */
.ecs-rc-notice {
    max-width: 720px; margin: 48px auto; padding: 22px 26px;
    background: #fff; border: 1px solid var(--rc-line); border-left: 4px solid var(--rc-gold);
    border-radius: 10px; color: var(--rc-muted); font-size: 16px;
}
.ecs-rc-notice i { color: var(--rc-gold); margin-right: 8px; }

/* Preview bar */
.ecs-rc-preview-bar {
    background: #fff7e6; border-bottom: 1px solid #f0d9a8; color: #8a6300;
    padding: 10px 18px; text-align: center; font-size: 14px;
}
.ecs-rc-preview-bar i { margin-right: 6px; }

/* ── Hero ── */
.ecs-rc-hero {
    position: relative; background-size: cover; background-position: center;
    min-height: 360px; display: flex; align-items: flex-end;
}
.ecs-rc-hero__overlay {
    position: absolute; inset: 0;
    background: linear-gradient(180deg, rgba(12,31,63,.45) 0%, rgba(12,31,63,.88) 100%);
}
.ecs-rc-hero__inner {
    position: relative; max-width: 1080px; margin: 0 auto; width: 100%;
    padding: 48px 24px; color: #fff;
}
.ecs-rc-eyebrow {
    display: inline-block; font-size: 13px; font-weight: 600; letter-spacing: .12em;
    text-transform: uppercase; color: var(--rc-gold-2); margin-bottom: 14px;
}
.ecs-rc-eyebrow i { margin-right: 6px; }
.ecs-rc-hero__title {
    font-size: clamp(28px, 4.4vw, 46px); line-height: 1.12; font-weight: 800;
    margin: 0 0 16px; color: #fff; max-width: 18ch;
}
.ecs-rc-hero__meta { display: flex; flex-wrap: wrap; gap: 22px; font-size: 15px; color: #dbe2ee; }
.ecs-rc-hero__meta i { color: var(--rc-gold-2); margin-right: 7px; }

/* ── Layout ── */
.ecs-rc-container { max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.ecs-rc-section { padding: 56px 0; border-bottom: 1px solid var(--rc-line); }
.ecs-rc-section:last-of-type { border-bottom: none; }
.ecs-rc-sechd { text-align: center; max-width: 640px; margin: 0 auto 40px; }
.ecs-rc-sechd h2 {
    font-size: clamp(24px, 3vw, 32px); font-weight: 800; color: var(--rc-navy); margin: 0 0 10px;
}
.ecs-rc-sechd h2 i { color: var(--rc-gold); margin-right: 10px; }
.ecs-rc-sechd p { color: var(--rc-muted); font-size: 16px; margin: 0; }

/* ── Podium ── */
.ecs-rc-podium {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; align-items: end;
    max-width: 880px; margin: 0 auto;
}
.ecs-rc-podium-item {
    background: #fff; border: 1px solid var(--rc-line); border-radius: 14px;
    padding: 30px 22px 26px; text-align: center; position: relative;
    box-shadow: 0 8px 28px rgba(12,31,63,.06);
}
.ecs-rc-podium--1 { border-top: 4px solid var(--rc-gold); padding-top: 40px; }
.ecs-rc-podium--2 { border-top: 4px solid #b9c0cc; }
.ecs-rc-podium--3 { border-top: 4px solid #c98a5a; }
.ecs-rc-podium-badge {
    width: 58px; height: 58px; border-radius: 50%; margin: 0 auto 14px;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px; color: #fff; background: var(--rc-navy);
}
.ecs-rc-podium--1 .ecs-rc-podium-badge { background: linear-gradient(135deg, var(--rc-gold), var(--rc-gold-2)); width: 66px; height: 66px; font-size: 28px; }
.ecs-rc-podium--2 .ecs-rc-podium-badge { background: #97a0ae; }
.ecs-rc-podium--3 .ecs-rc-podium-badge { background: #c98a5a; }
.ecs-rc-podium-rank { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--rc-gold); margin-bottom: 8px; }
.ecs-rc-podium-name { font-size: 19px; font-weight: 700; color: var(--rc-navy); margin: 0 0 4px; }
.ecs-rc-podium-school { font-size: 14px; color: var(--rc-muted); margin: 0 0 10px; }
.ecs-rc-podium-essay { font-size: 14px; font-style: italic; color: #4b5563; margin: 0; }

/* ── Honour roll ── */
.ecs-rc-honour { margin-top: 44px; }
.ecs-rc-honour-title { text-align: center; font-size: 15px; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: var(--rc-muted); margin: 0 0 22px; }
.ecs-rc-honour-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 16px; }
.ecs-rc-honour-card {
    background: #fff; border: 1px solid var(--rc-line); border-radius: 12px; padding: 18px 20px;
}
.ecs-rc-honour-tag {
    display: inline-block; font-size: 11px; font-weight: 700; letter-spacing: .04em;
    color: var(--rc-navy); background: #eef1f6; padding: 3px 10px; border-radius: 20px; margin-bottom: 10px;
}
.ecs-rc-honour-card h4 { font-size: 16px; font-weight: 700; color: var(--rc-navy); margin: 0 0 3px; }
.ecs-rc-honour-school { font-size: 13px; color: var(--rc-muted); margin: 0 0 8px; }
.ecs-rc-honour-essay { font-size: 13px; font-style: italic; color: #4b5563; margin: 0; }

/* ── Write-up ── */
.ecs-rc-writeup { max-width: 760px; margin: 0 auto; font-size: 17px; color: #374151; }
.ecs-rc-writeup p { margin: 0 0 1em; }
.ecs-rc-writeup h2, .ecs-rc-writeup h3 { color: var(--rc-navy); }

/* ── Galleries ── */
.ecs-rc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.ecs-rc-tile {
    position: relative; padding: 0; border: none; cursor: pointer; overflow: hidden;
    border-radius: 10px; aspect-ratio: 4 / 3; background: #eceef2; display: block;
}
.ecs-rc-tile img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .4s ease; }
.ecs-rc-tile:hover img { transform: scale(1.06); }
.ecs-rc-tile:after {
    content: "\f00e"; font-family: "Font Awesome 6 Free"; font-weight: 900;
    position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
    color: #fff; font-size: 22px; background: rgba(12,31,63,.0); opacity: 0; transition: .25s;
}
.ecs-rc-tile:hover:after { background: rgba(12,31,63,.35); opacity: 1; }

/* ── Stats ── */
.ecs-rc-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 18px; max-width: 820px; margin: 0 auto; }
.ecs-rc-stat { text-align: center; padding: 26px 16px; background: var(--rc-navy); border-radius: 14px; color: #fff; }
.ecs-rc-stat-num { display: block; font-size: 38px; font-weight: 800; line-height: 1; color: var(--rc-gold-2); margin-bottom: 8px; }
.ecs-rc-stat-lbl { font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: #c2cbdb; }

/* ── CTA ── */
.ecs-rc-cta { text-align: center; padding: 60px 24px; background: linear-gradient(135deg, var(--rc-navy), var(--rc-navy-2)); color: #fff; }
.ecs-rc-cta h2 { font-size: 28px; font-weight: 800; margin: 0 0 10px; color: #fff; }
.ecs-rc-cta p { color: #c7d0df; margin: 0 0 24px; font-size: 16px; }
.ecs-rc-cta-btn {
    display: inline-flex; align-items: center; gap: 10px; text-decoration: none;
    background: linear-gradient(135deg, var(--rc-gold), var(--rc-gold-2)); color: #1a1206;
    font-weight: 700; font-size: 16px; padding: 14px 30px; border-radius: 50px; transition: transform .15s, box-shadow .15s;
}
.ecs-rc-cta-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(201,147,58,.4); color: #1a1206; }

/* ── Lightbox ── */
.ecs-rc-lightbox {
    position: fixed; inset: 0; z-index: 100000; display: none;
    align-items: center; justify-content: center; background: rgba(8,16,32,.92);
}
.ecs-rc-lightbox.is-open { display: flex; }
.ecs-rc-lightbox img { max-width: 90vw; max-height: 86vh; border-radius: 6px; box-shadow: 0 12px 50px rgba(0,0,0,.5); }
.ecs-rc-lb-close, .ecs-rc-lb-nav {
    position: absolute; background: rgba(255,255,255,.12); color: #fff; border: none;
    cursor: pointer; border-radius: 50%; transition: background .2s;
}
.ecs-rc-lb-close { top: 22px; right: 26px; width: 46px; height: 46px; font-size: 28px; line-height: 1; }
.ecs-rc-lb-nav { top: 50%; transform: translateY(-50%); width: 52px; height: 52px; font-size: 22px; }
.ecs-rc-lb-prev { left: 24px; }
.ecs-rc-lb-next { right: 24px; }
.ecs-rc-lb-close:hover, .ecs-rc-lb-nav:hover { background: rgba(255,255,255,.28); }

/* ── Responsive ── */
@media (max-width: 720px) {
    .ecs-rc-podium { grid-template-columns: 1fr; }
    .ecs-rc-podium--1 { order: -1; padding-top: 30px; }
    .ecs-rc-hero { min-height: 280px; }
    .ecs-rc-lb-nav { width: 42px; height: 42px; }
    .ecs-rc-lb-prev { left: 8px; }
    .ecs-rc-lb-next { right: 8px; }
}
