/* EventLander - Reusable Event Landing Page Styles
   Author: C. Doherty | Date: 2026-02-12 */

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

body {
    font-family: 'DM Sans', sans-serif;
    color: var(--color-text);
    background: var(--color-bg);
    line-height: 1.65;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Sora', sans-serif;
    line-height: 1.2;
}

a { color: var(--color-primary); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; height: auto; }

/* === Layout === */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 1.5rem; }
.container-narrow { max-width: 600px; }

/* === Hero === */
.hero {
    position: relative;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    color: #fff;
    text-align: center;
    padding: 6rem 1.5rem 5rem;
    background-size: cover;
    background-position: center;
}
.hero-sm { padding: 5.5rem 1.5rem 3rem; }

.hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 20% 50%, rgba(255,255,255,0.12) 0%, transparent 60%),
        radial-gradient(ellipse at 80% 20%, rgba(255,255,255,0.08) 0%, transparent 50%);
    pointer-events: none;
    z-index: 1;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 32px;
    background: var(--color-bg);
    clip-path: ellipse(55% 100% at 50% 100%);
    z-index: 2;
}

/* === Page Logo (upper-left) === */
.page-logo {
    position: absolute;
    top: 1.25rem;
    left: 1.5rem;
    z-index: 10;
    animation: fadeInUp 0.7s ease-out 0.1s both;
    background: #fff;
    padding: 0.5rem 0.75rem;
    border-radius: var(--radius);
}
.page-logo img {
    max-height: 60px;
    display: block;
}

.hero-inner { max-width: var(--max-width); margin: 0 auto; position: relative; z-index: 3; }
.hero-logo { max-height: 120px; margin-bottom: 1.5rem; animation: fadeInUp 0.7s ease-out 0.1s both; }
.hero-title {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
    letter-spacing: -0.03em;
    animation: fadeInUp 0.7s ease-out 0.15s both;
}
.hero-tagline {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 1.5rem;
    font-weight: 300;
    animation: fadeInUp 0.7s ease-out 0.25s both;
}
.hero-meta {
    font-size: 1.05rem;
    opacity: 0.85;
    margin-bottom: 0.25rem;
    animation: fadeInUp 0.7s ease-out 0.35s both;
}
.hero-divider { margin: 0 0.5rem; }
.hero .btn { animation: fadeInUp 0.7s ease-out 0.45s both; }

/* === Sections === */
.section { padding: 4.5rem 0; }
.section-alt {
    background: linear-gradient(180deg, var(--color-bg-alt) 0%, var(--color-bg) 100%);
}
.section-title {
    font-size: 1.85rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    text-align: center;
    letter-spacing: -0.02em;
}
.section-text {
    max-width: 700px;
    font-size: 1.1rem;
    color: var(--color-text-light);
    text-align: left;
    line-height: 1.8;
}

/* === Buttons === */
.btn {
    display: inline-block;
    padding: 0.75rem 2rem;
    border-radius: var(--radius);
    font-family: 'Sora', sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    border: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
    text-decoration: none;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); text-decoration: none; }
.btn:active { transform: translateY(0); box-shadow: var(--shadow); }
.btn-primary { background: var(--color-primary); color: #fff; }
.btn-secondary { background: var(--color-bg); color: var(--color-text); border: 1px solid var(--color-border); }
.btn-lg { padding: 1rem 2.5rem; font-size: 1.05rem; margin-top: 1.5rem; }
.btn-block { display: block; width: 100%; }
.btn:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

/* === Speakers Grid === */
.speakers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
    margin-top: 1rem;
}
.speaker-card {
    text-align: center;
    padding: 1.5rem 1rem;
    border-radius: calc(var(--radius) + 4px);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.speaker-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 24px rgba(0,0,0,0.08);
}
.speaker-photo {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin-bottom: 1rem;
    border: 3px solid var(--color-border);
}
.speaker-photo-placeholder {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: var(--color-primary);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Sora', sans-serif;
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 auto 1rem;
}
.speaker-name { font-size: 1.1rem; font-weight: 600; margin-bottom: 0.25rem; }
.speaker-title { font-size: 0.9rem; color: var(--color-text-light); margin-bottom: 0.5rem; }
.speaker-bio { font-size: 0.85rem; color: var(--color-text-light); line-height: 1.6; }

/* === Agenda === */
.agenda { max-width: 700px; margin: 0 auto; }
.agenda-item {
    display: flex;
    gap: 1.5rem;
    padding: 1.25rem 0;
    border-bottom: 1px solid var(--color-border);
}
.agenda-item:last-child { border-bottom: none; }
.agenda-time {
    flex-shrink: 0;
    width: 100px;
    font-weight: 600;
    color: var(--color-primary);
    font-size: 0.95rem;
    padding-left: 1.25rem;
    position: relative;
}
.agenda-time::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0.4em;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--color-primary);
}
.agenda-title { font-weight: 600; margin-bottom: 0.25rem; }
.agenda-desc { font-size: 0.9rem; color: var(--color-text-light); }

/* === Tickets Grid === */
.tickets-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 1rem;
}
.ticket-card {
    background: var(--color-bg);
    border: 2px solid var(--color-border);
    border-radius: calc(var(--radius) + 4px);
    padding: 2rem;
    text-align: center;
    transition: transform 0.3s ease, border-color 0.2s ease, box-shadow 0.3s ease;
}
.ticket-card:hover {
    border-color: var(--color-primary);
    transform: translateY(-4px);
    box-shadow: 0 16px 32px rgba(0,0,0,0.08);
}
.ticket-name { font-size: 1.1rem; font-weight: 600; margin-bottom: 0.5rem; }
.ticket-price {
    font-family: 'Sora', sans-serif;
    font-size: 2.25rem;
    font-weight: 800;
    color: var(--color-primary);
    margin-bottom: 0.5rem;
    letter-spacing: -0.02em;
}
.ticket-desc { font-size: 0.9rem; color: var(--color-text-light); margin-bottom: 0.5rem; }
.ticket-capacity { font-size: 0.8rem; color: var(--color-text-light); margin-bottom: 1rem; }

/* === Events Grid (Index Page) === */
.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}
.event-card {
    display: block;
    background: var(--color-bg);
    border: 1px solid var(--color-border);
    border-radius: calc(var(--radius) + 4px);
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.event-card:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
    text-decoration: none;
}
.event-card-header {
    padding: 2rem 1.5rem;
    background: linear-gradient(135deg, var(--color-primary, #2563EB), var(--color-secondary, #1E40AF));
    color: #fff;
    position: relative;
    overflow: hidden;
}
.event-card-header::before {
    content: '';
    position: absolute;
    right: -30px;
    bottom: -30px;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: rgba(255,255,255,0.08);
}
.event-card-header::after {
    content: '';
    position: absolute;
    right: 20px;
    top: -20px;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
}
.event-card-date {
    font-family: 'Sora', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    opacity: 0.9;
    margin-bottom: 0.5rem;
    letter-spacing: 0.02em;
}
.event-card-name {
    font-family: 'Sora', sans-serif;
    font-size: 1.3rem;
    font-weight: 700;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
}
.event-card-body { padding: 1.25rem 1.5rem; }
.event-card-venue {
    font-size: 0.9rem;
    color: var(--color-text-light);
    margin-bottom: 0.25rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
.event-card-venue-text {
    white-space: nowrap;
    overflow: hidden;
    min-width: 0;
}
.event-card-venue::before {
    content: '';
    display: inline-block;
    width: 14px;
    height: 14px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23999' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M17.657 16.657L13.414 20.9a1.998 1.998 0 01-2.827 0l-4.244-4.243a8 8 0 1111.314 0z'/%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M15 11a3 3 0 11-6 0 3 3 0 016 0z'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    flex-shrink: 0;
}
.event-card-tagline {
    font-size: 0.85rem;
    color: var(--color-text-light);
    margin-top: 0.25rem;
}
.event-card-footer {
    padding: 0 1.5rem 1.25rem;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    color: var(--color-primary);
    font-family: 'Sora', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    gap: 0.35rem;
}
.event-card-footer::after {
    content: '\2192';
    transition: transform 0.2s ease;
}
.event-card:hover .event-card-footer::after {
    transform: translateX(4px);
}

/* === Forms === */
.form-group { margin-bottom: 1.25rem; }
.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.4rem;
    font-size: 0.95rem;
}
.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius);
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.2s, box-shadow 0.2s;
    background: var(--color-bg);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}
.form-group input.error,
.form-group select.error { border-color: var(--color-error); box-shadow: 0 0 0 3px rgba(220, 38, 38, 0.08); }
.required { color: var(--color-error); }
.form-note { text-align: center; margin-top: 1rem; font-size: 0.9rem; color: var(--color-text-light); }
.hp-field { position: absolute; left: -9999px; opacity: 0; height: 0; width: 0; overflow: hidden; }

/* === Ticket Selection (Radio) === */
.ticket-select { display: flex; flex-direction: column; gap: 0.75rem; }
.ticket-option {
    display: block;
    border: 2px solid var(--color-border);
    border-radius: var(--radius);
    padding: 1rem 1.25rem;
    cursor: pointer;
    transition: border-color 0.2s, background 0.2s, box-shadow 0.2s;
}
.ticket-option:hover { border-color: var(--color-primary); }
.ticket-option.selected {
    border-color: var(--color-primary);
    background: rgba(37, 99, 235, 0.04);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.08);
}
.ticket-option input[type="radio"] { display: none; }
.ticket-option-inner { display: flex; align-items: center; flex-wrap: wrap; gap: 0.5rem; }
.ticket-option-name { font-weight: 600; }
.ticket-option-price { margin-left: auto; font-family: 'Sora', sans-serif; font-weight: 700; color: var(--color-primary); }
.ticket-option-desc { width: 100%; font-size: 0.85rem; color: var(--color-text-light); }
.ticket-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    background: var(--color-bg-alt);
    border-radius: var(--radius);
    font-weight: 600;
}

/* === Confirmation === */
.confirmation-card {
    text-align: center;
    padding: 2.5rem 2rem;
    border: 2px solid var(--color-border);
    border-radius: calc(var(--radius) + 4px);
    animation: fadeInUp 0.6s ease-out;
}
.confirmation-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 1.25rem;
    color: var(--color-success);
}
.confirmation-icon svg { width: 100%; height: 100%; }
.checkmark-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    animation: checkmarkStroke 0.6s ease-in-out 0.2s forwards;
}
.checkmark-check {
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    animation: checkmarkStroke 0.35s ease-in-out 0.65s forwards;
}
.confirmation-details {
    margin: 1.5rem 0;
    text-align: left;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}
.detail-row {
    display: flex;
    justify-content: space-between;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--color-border);
}
.detail-label { color: var(--color-text-light); font-size: 0.95rem; }
.detail-value { font-weight: 600; font-size: 0.95rem; }

/* === Venue === */
.venue-info { text-align: center; margin-bottom: 1.5rem; }
.venue-info h3 { font-size: 1.25rem; margin-bottom: 0.25rem; }
.venue-map { border-radius: calc(var(--radius) + 4px); overflow: hidden; box-shadow: var(--shadow); }

/* === CTA Section === */
.section-cta {
    background: linear-gradient(180deg, var(--color-bg-alt) 0%, var(--color-bg) 100%);
}

/* === Data Table === */
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}
.data-table th, .data-table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--color-border);
}
.data-table th {
    font-family: 'Sora', sans-serif;
    font-weight: 600;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--color-text-light);
    background: var(--color-bg-alt);
    position: sticky;
    top: 0;
}
.data-table tbody tr:hover { background: var(--color-bg-alt); }

/* === Badges === */
.badge {
    display: inline-block;
    padding: 0.2rem 0.6rem;
    border-radius: 100px;
    font-family: 'Sora', sans-serif;
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.badge-confirmed, .badge-completed { background: #d1fae5; color: #065f46; }
.badge-pending { background: #fef3c7; color: #92400e; }
.badge-cancelled, .badge-failed { background: #fee2e2; color: #991b1b; }
.badge-na { background: #e2e8f0; color: #475569; }
.badge-refunded { background: #e0e7ff; color: #3730a3; }

/* === Flash Messages === */
.flash-messages { max-width: var(--max-width); margin: 0 auto; padding: 1rem 1.5rem 0; }
.flash {
    padding: 0.75rem 1rem;
    border-radius: var(--radius);
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
}
.flash-error { background: #fee2e2; color: #991b1b; }
.flash-success { background: #d1fae5; color: #065f46; }
.flash-warning { background: #fef3c7; color: #92400e; }

/* === Footer === */
.site-footer {
    padding: 2.5rem 0;
    text-align: center;
    font-size: 0.85rem;
    color: var(--color-text-light);
    background: var(--color-bg-alt);
    border-top: 1px solid var(--color-border);
    margin-top: 2rem;
}

/* === Error Pages === */
.error-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-bg);
    text-align: center;
    padding: 2rem;
}
.error-code {
    font-family: 'Sora', sans-serif;
    font-size: 8rem;
    font-weight: 800;
    line-height: 1;
    letter-spacing: -0.04em;
    background: linear-gradient(135deg, var(--color-primary), var(--color-secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 0.5rem;
}
.error-message {
    font-family: 'Sora', sans-serif;
    font-size: 1.35rem;
    font-weight: 600;
    color: var(--color-text);
    margin-bottom: 0.5rem;
}
.error-hint {
    font-size: 0.95rem;
    color: var(--color-text-light);
    margin-bottom: 2rem;
    max-width: 400px;
}

/* === Animation Keyframes === */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(24px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes checkmarkStroke {
    to { stroke-dashoffset: 0; }
}

/* === Scroll Reveal === */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* === Responsive === */
@media (max-width: 768px) {
    .hero { padding: 4rem 1rem 3.5rem; }
    .hero-sm { padding: 2.5rem 1rem 2rem; }
    .hero-title { font-size: 2.2rem; }
    .hero-tagline { font-size: 1rem; }
    .hero::after { height: 20px; }
    .section { padding: 3rem 0; }
    .section-title { font-size: 1.4rem; }
    .agenda-item { flex-direction: column; gap: 0.25rem; }
    .agenda-time { width: auto; }
    .tickets-grid { grid-template-columns: 1fr; }
    .events-grid { grid-template-columns: 1fr; }
    .data-table { font-size: 0.8rem; }
    .data-table th, .data-table td { padding: 0.5rem; }
    .error-code { font-size: 5rem; }
}
