/* ==========================================================
   CrystalErice — shared "landing" design system
   Used by: /landing.php, /information.php, /venue.php
   ========================================================== */

/* ---- Design tokens ---- */
:root {
    --ce-blue:   #1b3255;
    --ce-blue2:  #243f6a;
    --ce-gold:   #e8711a;
    --ce-gold-l: #f0893a;
    --ce-light:  #f5f6f8;
    --ce-muted:  #6b7280;
}

/* ---- Base ---- */
html { scroll-behavior: smooth; }
body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif; }

/* ---- Smooth-scroll anchor offset (clears the sticky navbar) ---- */
section[id],
.ce-link-refer { scroll-margin-top: 76px; }

/* ---- Navbar ---- */
.ce-navbar { background: rgba(27, 50, 85, 0.96); backdrop-filter: blur(8px); }
.ce-navbar .uk-navbar-nav > li > a,
.ce-navbar .uk-navbar-item {
    color: rgba(255,255,255,0.8);
    font-size: 0.875rem;
    letter-spacing: 0.02em;
}
.ce-navbar .uk-navbar-nav > li > a:hover { color: var(--ce-gold-l); }
.ce-navbar-lodos:hover { color: var(--ce-gold) !important; }

/* ---- myErice dropdown ---- */
.ce-navbar .uk-dropdown {
    background: var(--ce-blue2);
    border: 1px solid rgba(255,255,255,0.12);
    border-top: 2px solid var(--ce-gold-l);
    border-radius: 3px;
    box-shadow: 0 12px 28px rgba(0,0,0,0.35);
    padding: 0.35rem;
    min-width: 170px;
}
.ce-navbar .uk-dropdown-nav > li > a {
    color: rgba(255,255,255,0.8);
    font-size: 0.85rem;
    padding: 0.55rem 0.75rem;
    border-radius: 3px;
    transition: background 0.15s, color 0.15s;
}
.ce-navbar .uk-dropdown-nav > li > a:hover {
    background: rgba(255,255,255,0.08);
    color: var(--ce-gold-l);
}
.ce-logo { color: var(--ce-gold) !important; font-size: 1.15rem; letter-spacing: -0.01em; }
.ce-logo strong { color: white; }

/* ---- Hero ---- */
.ce-hero {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background: url('/_imgs/tempio.webp') center 40% / cover no-repeat;
}
.ce-hero-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(160deg, rgba(27,50,85,0.88) 0%, rgba(27,50,85,0.55) 60%, rgba(0,0,0,0.4) 100%);
}
.ce-hero-content { position: relative; z-index: 1; }
.ce-hero-logo {
    height: clamp(135px, min(20vw, 20vh), 235px);
    width: auto;
    margin-bottom: 1.25rem;
    filter: drop-shadow(0 6px 24px rgba(0,0,0,0.35));
    animation: ce-logo-in 1.1s ease-out both;
}
.ce-hero-logo-divider {
    display: block;
    width: 64px;
    height: 2px;
    margin: 0 auto 1.1rem;
    background: linear-gradient(90deg, transparent, var(--ce-gold-l), transparent);
    opacity: 0.8;
}
@keyframes ce-logo-in {
    from { opacity: 0; transform: translateY(-12px) scale(0.96); }
    to   { opacity: 1; transform: translateY(0) scale(1); }
}
.ce-hero h1 {
    font-size: clamp(1.8rem, 4.5vw, 3.2rem);
    font-weight: 300;
    color: white;
    line-height: 1.15;
    letter-spacing: -0.02em;
}
.ce-hero h1 strong { color: var(--ce-gold-l); font-weight: 600; }
.ce-hero-sub {
    color: rgba(255,255,255,0.78);
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    max-width: 520px;
    margin: 0.9rem auto 1.5rem;
}
.ce-badge-est {
    display: inline-block;
    background: var(--ce-gold);
    color: white;
    font-size: 0.72rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    padding: 0.3rem 0.9rem;
    border-radius: 100px;
    margin-bottom: 0.9rem;
}
.ce-scroll-hint {
    position: absolute;
    bottom: 3.5rem;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255,255,255,0.45);
    animation: ce-bounce 2s infinite;
    z-index: 1;
}
@keyframes ce-bounce {
    0%, 100% { transform: translateX(-50%) translateY(0); }
    50%       { transform: translateX(-50%) translateY(7px); }
}

/* ---- Page hero (detail pages) ---- */
.ce-page-hero {
    min-height: 42vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    background-size: cover;
    background-position: center;
    margin-top: 0;
}
.ce-page-hero h1 {
    font-size: clamp(1.8rem, 4.5vw, 2.8rem);
    font-weight: 300;
    color: white;
    letter-spacing: -0.02em;
}
.ce-page-hero-sub {
    color: rgba(255,255,255,0.78);
    font-size: 0.95rem;
    max-width: 560px;
    margin: 0.75rem auto 0;
}
.ce-breadcrumb { position: relative; z-index: 1; font-size: 0.8rem; letter-spacing: 0.05em; margin-bottom: 0.75rem; }
.ce-breadcrumb a { color: rgba(255,255,255,0.65); text-decoration: none; }
.ce-breadcrumb a:hover { color: white; }
.ce-breadcrumb span { color: rgba(255,255,255,0.4); margin: 0 0.4rem; }

/* ---- School hero (split hero for single-course pages) ---- */
.ce-school-hero {
    background: linear-gradient(160deg, rgba(15,26,46,0.92) 0%, rgba(27,50,85,0.82) 45%, rgba(27,50,85,0.62) 100%), url('/2027/_img/mechano_hero.webp') center 35% / cover no-repeat;
    min-height: 85vh;
    display: flex;
    align-items: center;
}
.ce-school-hero-logo-col {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 1.5rem;
}
.ce-logo-placeholder {
    width: 100%;
    max-width: 480px;
    aspect-ratio: 1;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
}
.ce-logo-placeholder-year {
    font-size: clamp(2.6rem, 6vw, 4.2rem);
    font-weight: 700;
    color: white;
    letter-spacing: 0.02em;
    line-height: 1;
}
.ce-logo-placeholder-caption {
    font-size: 0.78rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    text-align: center;
    padding: 0 1rem;
    color: rgba(255,255,255,0.4);
}
.ce-school-hero-text-col { padding: 2rem 1.5rem 3rem; }
.ce-school-hero-title {
    font-size: clamp(2.2rem, 5vw, 4rem);
    font-weight: 300;
    color: white;
    line-height: 1.15;
    letter-spacing: -0.02em;
    margin: 1.1rem 0 0;
}
.ce-school-hero-sub {
    color: rgba(255,255,255,0.78);
    font-size: 1.05rem;
    margin: 1.4rem 0 0;
    max-width: 560px;
}
.ce-school-hero-sub strong { color: var(--ce-gold-l); font-weight: 600; }
.ce-school-hero-dates {
    font-size: clamp(1.4rem, 2.6vw, 2rem);
    font-weight: 600;
    color: var(--ce-gold-l);
    letter-spacing: 0.01em;
    margin: 1.1rem 0 0;
}
.ce-school-hero-meta {
    color: rgba(255,255,255,0.65);
    font-size: 0.9rem;
    margin: 1.1rem 0 0;
}
@media (max-width: 959px) {
    .ce-school-hero-text-col { text-align: center; }
    .ce-school-hero-sub { margin-left: auto; margin-right: auto; }
}


/* ---- Stats bar ---- */
.ce-stats { background: var(--ce-gold); }
.ce-stat-num  { font-size: 2.4rem; font-weight: 700; color: white; line-height: 1; }
.ce-stat-label { font-size: 0.75rem; color: rgba(255,255,255,0.85); text-transform: uppercase; letter-spacing: 0.1em; margin-top: 0.25rem; }

/* ---- Section headings ---- */
.ce-eyebrow {
    display: block;
    font-size: 0.75rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--ce-gold);
    margin-bottom: 0.5rem;
}
.ce-h2 { font-size: clamp(1.6rem, 3vw, 2.2rem); font-weight: 300; color: var(--ce-blue); line-height: 1.2; }
.ce-h2-light { color: white; }

/* ---- Buttons ---- */
.ce-btn-primary {
    background: var(--ce-gold);
    color: white;
    border: none;
    padding: 0.65rem 1.5rem;
    border-radius: 3px;
    font-size: 0.9rem;
    cursor: pointer;
    display: inline-block;
    transition: background 0.2s;
    text-decoration: none;
}
.ce-btn-primary:hover { background: var(--ce-gold-l); color: white; text-decoration: none; }
.ce-btn-outline {
    background: transparent;
    color: white;
    border: 1.5px solid rgba(255,255,255,0.55);
    padding: 0.65rem 1.5rem;
    border-radius: 3px;
    font-size: 0.9rem;
    cursor: pointer;
    display: inline-block;
    transition: border-color 0.2s, color 0.2s;
    text-decoration: none;
}
.ce-btn-outline:hover { border-color: white; color: white; text-decoration: none; }
.ce-btn-outline-dark {
    background: transparent;
    color: var(--ce-blue);
    border: 1.5px solid var(--ce-blue);
    padding: 0.65rem 1.5rem;
    border-radius: 3px;
    font-size: 0.9rem;
    cursor: pointer;
    display: inline-block;
    transition: background 0.2s, color 0.2s;
    text-decoration: none;
}
.ce-btn-outline-dark:hover { background: var(--ce-blue); color: white; text-decoration: none; }
.ce-btn-secondary {
    background: rgba(255,255,255,0.12);
    color: white;
    border: 1.5px solid rgba(255,255,255,0.35);
    padding: 0.5rem 1rem;
    border-radius: 3px;
    font-size: 0.8rem;
    cursor: pointer;
    display: inline-block;
    transition: background 0.2s, border-color 0.2s;
    text-decoration: none;
}
.ce-btn-secondary:hover { background: rgba(255,255,255,0.22); border-color: rgba(255,255,255,0.6); color: white; text-decoration: none; }

/* ---- About ---- */
.ce-about { background: white; }
.ce-about-img {
    border-radius: 4px;
    overflow: hidden;
    height: 420px;
    position: relative;
}
.ce-about-img img { width: 100%; height: 100%; object-fit: cover; }

/* ---- Venue ---- */
.ce-venue { background: var(--ce-blue); }
.ce-venue-card {
    background: rgba(255,255,255,0.07);
    border-radius: 4px;
    padding: 2rem;
    
    transition: background 0.2s;
}
.ce-venue-card:hover { background: rgba(255,255,255,0.11); }
.ce-venue-card h3 { color: white; font-weight: 400; font-size: 1.05rem; margin-top: 0.85rem; }
.ce-venue-card p  { color: rgba(255,255,255,0.62); font-size: 0.88rem; margin: 0; line-height: 1.65; }

/* ---- Next school ---- */
.ce-school-card {
    border-top: 4px solid var(--ce-gold);
    border-radius: 4px;
}
.ce-course-badge {
    background: var(--ce-blue);
    color: white;
    font-size: 0.75rem;
    padding: 0.25rem 0.7rem;
    border-radius: 100px;
    display: inline-block;
}

/* ---- Past schools ---- */
.ce-past { background: var(--ce-light); }
.ce-past-card {
    background: white;
    border-left: 3px solid var(--ce-gold);
    border-radius: 0 4px 4px 0;
    padding: 1rem 1.25rem;
    font-size: 0.88rem;
}
.ce-past-card strong { color: var(--ce-blue); font-size: 0.95rem; }
.ce-past-card span   { color: var(--ce-muted); display: block; margin-top: 0.15rem; }
.ce-future-card { border-left-color: var(--ce-blue); }

/* ---- Faculty (directors + speakers) ---- */
.ce-faculty { background: white; }
.ce-faculty-card {
    text-align: center;
    padding: 1rem 0.75rem 0;
}
.ce-faculty-seebio {
    display: inline-block;
    cursor: pointer;
    color: var(--ce-gold);
    background: transparent;
    border: 1px solid var(--ce-gold);
    border-radius: 100px;
    padding: 0.2rem 0.75rem;
    font-size: 0.72rem;
    letter-spacing: 0.02em;
    margin-top: 0.5rem;
    transition: background 0.15s ease, color 0.15s ease;
}
.ce-faculty-seebio:hover {
    background: var(--ce-gold);
    color: white;
}
.ce-faculty-seebio-disabled {
    cursor: not-allowed;
    opacity: 0.4;
    pointer-events: none;
}
.ce-faculty-seebio-disabled:hover {
    background: transparent;
    color: var(--ce-gold);
}
.ce-faculty-photo {
    width: 92px;
    height: 92px;
    margin: 0 auto 0.85rem;
    border-radius: 50%;
    background: var(--ce-light);
    border: 1px solid rgba(27,50,85,0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    color: rgba(27,50,85,0.25);
    overflow: hidden;
}
.ce-faculty-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    filter: grayscale(100%);
    transition: filter 0.35s ease, transform 0.35s ease;
}
.ce-faculty-photo:hover img,
.ce-faculty-photo:focus-within img {
    filter: grayscale(0%);
    transform: scale(1.05);
}
.ce-faculty-photo {
    transition: border-color 0.35s ease;
}
.ce-faculty-photo:hover,
.ce-faculty-photo:focus-within {
    border-color: var(--ce-gold);
}
.uk-modal-body .ce-faculty-photo img {
    filter: grayscale(0%);
}
.uk-modal-body .ce-faculty-photo:hover img,
.uk-modal-body .ce-faculty-photo:focus-within img {
    transform: none;
}
.ce-faculty-photo-clickable { cursor: pointer; }
.ce-faculty-photo-lg { width: 148px; height: 148px; }
.ce-faculty-card strong {
    display: block;
    color: var(--ce-blue);
    font-size: 0.92rem;
    font-weight: 600;
}
.ce-faculty-card-director strong { font-size: 1.1rem; }
.ce-faculty-affil {
    display: block;
    color: var(--ce-gold);
    font-size: 0.78rem;
    margin-top: 0.2rem;
}
.ce-faculty-bio {
    color: var(--ce-muted);
    font-size: 0.82rem;
    line-height: 1.55;
    margin: 0.5rem 0 0;
}
.ce-faculty-card-director .ce-faculty-bio { font-size: 0.86rem; max-width: 300px; margin-left: auto; margin-right: auto; }
.ce-faculty-divider {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--ce-muted);
    font-size: 0.78rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    margin: 0 0 2.5rem;
}
.ce-faculty-divider::before,
.ce-faculty-divider::after {
    content: "";
    flex: 1;
    height: 1px;
    background: rgba(27,50,85,0.1);
}

/* ---- Sponsors ---- */
.ce-sponsors-tier { margin-bottom: 3rem; }
.ce-sponsors-tier:last-child { margin-bottom: 0; }
.ce-sponsors-tba { color: var(--ce-muted); font-size: 0.85rem; }
.ce-sponsor-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1.25rem;
}
.ce-sponsor-logo a { display: block; }
.ce-sponsor-logo img {
    max-width: 100%;
}
.ce-sponsor-logo-diamond img { max-height: 88px; }
.ce-sponsor-logo-gold img { max-height: 66px; }
.ce-sponsor-logo-ruby img { max-height: 50px; }

/* ---- Practical info (cost / grants / visa) ---- */
.ce-info { background: var(--ce-light); }
.ce-info-card {
    background: white;
    border-radius: 4px;
    padding: 2rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.ce-info-card h3 { color: var(--ce-blue); font-weight: 400; font-size: 1.1rem; margin: 0.85rem 0 0.5rem; }
.ce-info-card p { color: var(--ce-muted); font-size: 0.88rem; line-height: 1.65; }

/* ---- Detail pages (information.php, venue.php) ---- */
.ce-pillnav { display: flex; gap: 0.6rem; flex-wrap: wrap; justify-content: center; }
.ce-pillnav a {
    display: inline-block;
    padding: 0.4rem 1rem;
    border-radius: 100px;
    border: 1.5px solid #e5e7eb;
    color: var(--ce-blue);
    font-size: 0.82rem;
    text-decoration: none;
    transition: background 0.2s, color 0.2s, border-color 0.2s;
}
.ce-pillnav a:hover { background: var(--ce-gold); border-color: var(--ce-gold); color: white; }
.ce-pillnav a.ce-pillnav-solid { background: var(--ce-blue); border-color: var(--ce-blue); color: white; }
.ce-pillnav a.ce-pillnav-solid:hover { background: var(--ce-blue2); border-color: var(--ce-blue2); color: white; }

.ce-detail-panel {
    background: white;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.06);
    padding: 2.25rem;
    margin-bottom: 2rem;
}
.ce-detail-panel h2 {
    color: var(--ce-blue);
    font-weight: 400;
    font-size: 1.35rem;
    margin: 0 0 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--ce-gold);
}
.ce-detail-img {
    width: 100%;
    height: 240px;
    object-fit: cover;
    border-radius: 4px;
    margin-bottom: 1.5rem;
}
.ce-detail-img-contain {
    max-width: 100%;
    max-height: 480px;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 4px;
    margin: 0 auto 1.5rem;
    display: block;
}
.ce-detail-panel p { color: var(--ce-muted); font-size: 0.92rem; line-height: 1.75; }
.ce-detail-panel ul { color: var(--ce-muted); font-size: 0.92rem; line-height: 1.75; padding-left: 1.1rem; }
.ce-detail-panel li { margin-bottom: 0.4rem; }
.ce-detail-panel h4 { color: var(--ce-blue); font-size: 0.95rem; font-weight: 600; margin: 1.25rem 0 0.5rem; }
.ce-detail-panel a { color: var(--ce-gold); }
.ce-detail-panel a:hover { color: var(--ce-gold-l); }

.ce-fact-list { list-style: none; margin: 0; padding: 0; }
.ce-fact-list li {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f1f3;
    font-size: 0.88rem;
}
.ce-fact-list li:last-child { border-bottom: none; }
.ce-fact-list .ce-fact-role { color: var(--ce-muted); }
.ce-fact-list .ce-fact-name { color: var(--ce-blue); font-weight: 500; text-align: right; }

.ce-alert-warning {
    background: #fff7ed;
    border-left: 4px solid var(--ce-gold);
    padding: 1rem 1.25rem;
    border-radius: 0 4px 4px 0;
    color: #7c4a03;
    font-size: 0.85rem;
    line-height: 1.6;
    margin-bottom: 2rem;
}

/* ---- Programme ---- */
.ce-programme { background: var(--ce-light); padding-top: 0; }
.ce-prog-tab { border-bottom: 1px solid #e6e8ec; }
.ce-prog-tab > * > a {
    color: var(--ce-muted);
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding-bottom: 0.7rem;
}
.ce-prog-tab > .uk-active > a { color: var(--ce-blue); border-color: var(--ce-gold); }
.ce-prog-tab > * > a:hover { color: var(--ce-blue); border-color: var(--ce-gold-l); }

.ce-prog-table { background: white; font-size: 0.88rem; }
.ce-prog-table thead th {
    border-bottom: 1px solid #e6e8ec;
    color: var(--ce-muted);
    font-weight: 500;
    font-size: 0.68rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    padding-bottom: 0.6rem;
}
.ce-prog-table td {
    color: var(--ce-muted);
    vertical-align: top;
    padding-top: 0.85rem;
    padding-bottom: 0.85rem;
}
.ce-prog-table tbody tr { border-top: 1px solid #f0f1f3; }
.ce-prog-table td strong { display: block; color: var(--ce-blue); font-weight: 500; }
.ce-prog-time { color: var(--ce-blue); font-weight: 500; }
.ce-prog-type {
    display: block;
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    margin-bottom: 0.2rem;
}
.ce-prog-meta { display: block; color: var(--ce-muted); font-size: 0.78rem; margin-top: 0.2rem; }

/* ---- Footer ---- */
.ce-footer { background: #111827; color: rgba(255,255,255,0.55); padding: 4rem 0 2rem; }
.ce-footer-logo { font-size: 1.15rem; color: var(--ce-gold); margin-bottom: 0.75rem; display: block; }
.ce-footer-logo strong { color: rgba(255,255,255,0.9); }
.ce-footer h4 {
    color: rgba(255,255,255,0.75);
    font-weight: 500;
    font-size: 0.78rem;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin-bottom: 1rem;
}
.ce-footer a { color: rgba(255,255,255,0.5); text-decoration: none; }
.ce-footer a:hover { color: var(--ce-gold-l); }
.ce-footer ul { list-style: none; padding: 0; margin: 0; }
.ce-footer ul li { margin-bottom: 0.5rem; font-size: 0.9rem; }
.ce-footer hr { border-color: rgba(255,255,255,0.08); margin: 3rem 0 1.5rem; }

/* ---- Back to top ---- */
.ce-totop {
    position: fixed;
    right: 1.5rem;
    bottom: 1.5rem;
    z-index: 980;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--ce-gold);
    color: white;
    border-radius: 50%;
    box-shadow: 0 2px 10px rgba(0,0,0,0.25);
    transition: background 0.2s ease;
}
.ce-totop:hover { background: var(--ce-gold-l); color: white; }
.ce-footer-bottom { font-size: 0.78rem; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 0.5rem; }
