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

:root {
    --accent-color: #437356;
}

body {
    font-family: 'DM Sans', ui-sans-serif, system-ui, sans-serif;
    background: #F2F3F4;
    min-height: 100vh;
    padding: 0;
    transition: background 0.3s ease;
    color: #1E4147;
}

body.dark-mode {
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
    color: #fff;
}

/* New Page Header (for non-front-page pages) */
.page-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: #437356;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding: 0;
}

.page-header-content {
    max-width: 1220px;
    margin: 0 auto;
    padding: 15px 20px;
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

.page-header-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.page-header-logo img {
    height: 35px;
    width: auto;
}

.page-header-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-left: 10px;
}

.nav-icon-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    color: white;
    text-decoration: none;
    padding: 6px 10px;
    border-radius: 8px;
    transition: background 0.2s;
}

.nav-icon-btn:hover {
    background: rgba(255, 255, 255, 0.18);
}

.nav-icon-img {
    width: 22px;
    height: 22px;
    filter: brightness(0) invert(1);
    display: block;
}

.nav-icon-label {
    font-size: 10px;
    font-weight: 500;
    white-space: nowrap;
    color: rgba(255, 255, 255, 0.9);
    line-height: 1;
}

.nav-dropdown {
    position: relative;
}

.nav-dropdown-link {
    color: white;
    font-weight: 500;
    font-size: 15px;
    cursor: pointer;
    padding: 8px 12px;
    display: inline-block;
    transition: opacity 0.2s;
    text-decoration: none;
}

.nav-dropdown-link:hover {
    opacity: 0.8;
}

.nav-dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    min-width: 160px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: opacity 0.2s, transform 0.2s, visibility 0.2s;
    z-index: 1000;
    margin-top: 5px;
}

.nav-dropdown:hover .nav-dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.nav-dropdown-item {
    display: block;
    padding: 12px 16px;
    color: #1f2937;
    text-decoration: none;
    transition: background 0.2s;
    font-size: 14px;
}

.nav-dropdown-item:hover {
    background: #f3f4f6;
}

.nav-dropdown-item:first-child {
    border-radius: 8px 8px 0 0;
}

.nav-dropdown-item:last-child {
    border-radius: 0 0 8px 8px;
}

.page-header-right {
    display: flex;
    align-items: center;
    margin-left: auto;
}

.page-header-login {
    padding: 8px 20px;
    background: #437356;
    color: white;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: transform 0.2s, box-shadow 0.2s;
}

.page-header-login:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(67, 115, 86, 0.35);
    background: #1E4147;
}

/* User Menu in Page Header */
.page-header .user-menu {
    position: relative;
    display: flex;
    align-items: center;
}

.page-header .user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid #437356;
    transition: border-color 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    flex-shrink: 0;
}

.page-header .user-avatar img,
.page-header .user-dropdown-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.avatar-initials {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #437356;
    color: white;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 0.5px;
    border-radius: 50%;
    flex-shrink: 0;
}

.page-header .user-avatar:hover {
    border-color: #AAC789;
}

.page-header .user-dropdown {
    position: absolute;
    right: 0;
    top: 55px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    min-width: 200px;
    display: none;
    z-index: 1001;
}

.page-header .user-dropdown.show {
    display: block;
}

.page-header .user-dropdown-header {
    padding: 12px;
    border-bottom: 1px solid #e5e7eb;
}

.page-header .user-dropdown-header-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.page-header .user-dropdown-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.page-header .user-dropdown-name {
    display: flex;
    flex-direction: column;
    color: #374151;
}

.page-header .user-dropdown-name strong {
    font-size: 14px;
}

.page-header .user-dropdown-name small {
    font-size: 12px;
    color: #6b7280;
}

.page-header .user-dropdown-link {
    display: block;
    padding: 10px 15px;
    color: #374151;
    text-decoration: none;
    font-size: 14px;
    transition: background 0.2s;
}

.page-header .user-dropdown-link:hover {
    background: #f3f4f6;
}

.page-header .user-dropdown-link.logout {
    color: #F34A53;
    border-top: 1px solid #e5e7eb;
}

/* Page Content Container */
/* base margin for all users; admins/org-admins get extra 22px via body.has-admin-strip */
.page-content {
    max-width: 1220px;
    margin: 80px auto 40px;
    padding: 20px;
}
body.has-admin-strip .page-content {
    margin-top: 102px;
}
/* Admin pages: no horizontal constraints so 1400px content and submenu align */
body.has-admin-strip .page-content.admin-layout {
    max-width: none;
    padding-left: 0;
    padding-right: 0;
}

/* Old container styles for backward compatibility */

.container {
    max-width: 1200px;
    margin: 0 auto;
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    transition: background-color 0.3s ease, color 0.3s ease;
}

body.dark-mode .container {
    background: #1e1e1e;
    color: #fff;
}

header {
    background: #437356;
    color: white;
    padding: 30px;
    text-align: center;
}

header .header-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.submenu {
    background: #1E4147;
    padding: 12px 30px;
    margin: 20px -30px -30px -30px;
    display: flex;
    gap: 24px;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.submenu-link {
    color: white;
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 4px;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.2s;
}

.submenu-link:hover {
    background: rgba(255, 255, 255, 0.15);
}

.submenu-link.active {
    background: rgba(255, 255, 255, 0.25);
    font-weight: 600;
}

.header-nav {
    display: flex;
    gap: 15px;
}

.nav-link {
    color: white;
    text-decoration: none;
    padding: 8px 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 5px;
    font-weight: 600;
    transition: all 0.3s;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: white;
}

.profile-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    font-size: 1.5em;
    border-radius: 50%;
    border-color: rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
}

.profile-icon:hover {
    background: rgba(255, 255, 255, 0.3);
    border-color: white;
    transform: scale(1.1);
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.5);
    object-fit: cover;
    cursor: pointer;
    transition: all 0.3s ease;
}

.user-avatar:hover {
    border-color: white;
    transform: scale(1.1);
}

.user-menu {
    position: relative;
    display: inline-block;
}

.user-dropdown {
    position: absolute;
    right: 0;
    top: 50px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    min-width: 200px;
    padding: 0;
    display: none;
    z-index: 1000;
}

.user-dropdown.show {
    display: block;
}

.user-dropdown-header {
    padding: 12px 16px;
    border-bottom: 1px solid #eee;
    background: #f9f9f9;
    border-radius: 8px 8px 0 0;
}

.user-dropdown-header-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.user-dropdown-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #ddd;
}

.user-dropdown-name {
    display: flex;
    flex-direction: column;
}

.user-dropdown-name strong {
    color: #333;
    font-weight: 600;
    font-size: 14px;
}

.user-dropdown-name small {
    color: #666;
    font-size: 0.85em;
}

.user-dropdown-link {
    display: block;
    padding: 12px 16px;
    color: #333;
    text-decoration: none;
    border-bottom: 1px solid #eee;
    transition: background 0.2s;
}

.user-dropdown-link:last-child {
    border-bottom: none;
}

.user-dropdown-link:hover {
    background: #f5f5f5;
}

.user-dropdown-link.logout {
    color: #F34A53;
}

.user-dropdown-link.logout:hover {
    background: #fff0f0;
}

header h1 {
    font-size: 2.5em;
    margin-bottom: 10px;
}

header p {
    font-size: 1.1em;
    opacity: 0.9;
}

.content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    padding: 30px;
}

.form-section h3,
.map-section h3 {
    margin-bottom: 20px;
    color: #333;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
}

.form-group input[type="text"],
.form-group input[type="date"],
.form-group input[type="time"],
.form-group input[type="file"] {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 5px;
    font-size: 1em;
    transition: border-color 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: #437356;
    box-shadow: 0 0 5px rgba(67, 115, 86, 0.3);
}

.radio-group {
    display: flex;
    gap: 20px;
}

.radio-group label {
    display: flex;
    align-items: center;
    margin-bottom: 0;
    font-weight: 500;
    cursor: pointer;
}

.radio-group input[type="radio"] {
    margin-right: 8px;
    cursor: pointer;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.preview {
    margin-top: 10px;
    max-width: 150px;
    border-radius: 5px;
}

.preview img {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
}

.btn-primary {
    width: 100%;
    padding: 14px;
    background: #437356;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(67, 115, 86, 0.4);
    background: #1E4147;
}

.btn-primary:active {
    transform: translateY(0);
}

#map {
    width: 100%;
    height: 400px;
    border-radius: 12px;
    border: 1px solid #e5e7eb;
    margin-bottom: 15px;
    background: #f0f0f0;
    z-index: 1;
}

.map-section {
    width: 100%;
    min-height: 400px;
}

.map-info {
    padding: 10px;
    background: #f5f5f5;
    border-radius: 5px;
    text-align: center;
}

.map-info p {
    color: #666;
    font-size: 0.9em;
}

.result-section {
    padding: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 600px;
}

.result-card {
    background: white;
    border-radius: 10px;
    padding: 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.1);
    max-width: 600px;
    width: 100%;
}

.result-card h2 {
    text-align: center;
    color: #437356;
    margin-bottom: 30px;
    font-size: 1.8em;
}

.result-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.qr-code,
.event-details {
    text-align: center;
}

.qr-code h3,
.event-details h3 {
    margin-bottom: 15px;
    color: #333;
}

#qrCode {
    display: flex;
    justify-content: center;
}

.event-details ul {
    list-style: none;
    text-align: left;
}

.event-details li {
    padding: 10px 0;
    border-bottom: 1px solid #e0e0e0;
    color: #555;
}

.event-details li:last-child {
    border-bottom: none;
}

.event-details strong {
    color: #437356;
}

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

    .form-row {
        grid-template-columns: 1fr;
    }

    header h1 {
        font-size: 1.8em;
    }

    .result-content {
        grid-template-columns: 1fr;
    }

    .result-card {
        padding: 20px;
    }
}

.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #437356;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes checkin-pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(0.7); }
}

.error-message {
    color: #e74c3c;
    padding: 10px;
    background: #fadbd8;
    border-radius: 5px;
    margin-bottom: 15px;
    display: none;
}

.error-message.show {
    display: block;
}

.success-message {
    color: #27ae60;
    padding: 10px;
    background: #d5f4e6;
    border-radius: 5px;
    margin-bottom: 15px;
    display: none;
}

.success-message.show {
    display: block;
}

/* EVENTS LIST PAGE STYLES */

.events-header {
    padding: 30px;
    background: #f9f9f9;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.search-section {
    flex: 1;
    min-width: 250px;
}

.search-box {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e0e0e0;
    border-radius: 5px;
    font-size: 1em;
    transition: border-color 0.3s;
}

.search-box:focus {
    outline: none;
    border-color: #437356;
    box-shadow: 0 0 5px rgba(67, 115, 86, 0.3);
}

.filter-section {
    padding: 20px 30px;
    background: #F2F3F4;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

.filter-section label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-weight: 500;
    color: #333;
}

.filter-section input[type="radio"] {
    margin-right: 8px;
    cursor: pointer;
}

.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
    padding: 30px;
}

.event-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.event-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.event-card-header {
    height: 180px;
    background: #f5f5f5;
    overflow: hidden;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.card-logo {
    max-width: 100%;
    max-height: 100%;
    object-fit: cover;
}

.card-logo-placeholder {
    font-size: 60px;
    color: #ccc;
}

.badge {
    position: absolute;
    top: 10px;
    right: 10px;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.75em;
    font-weight: 600;
    color: white;
}

.badge-public {
    background: #437356;
}

.badge-private {
    background: #F34A53;
}

.event-card-body {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.event-card-body h4 {
    color: #333;
    margin-bottom: 8px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.event-organization {
    color: #437356;
    font-size: 0.9em;
    font-weight: 600;
    margin-bottom: 15px;
}

.event-card-details {
    display: flex;
    flex-direction: column;
    gap: 10px;
    color: #666;
    font-size: 0.9em;
    flex: 1;
}

.detail {
    display: flex;
    gap: 8px;
    align-items: flex-start;
}

.detail .label {
    min-width: 20px;
}

.detail .value {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.event-card-footer {
    padding: 0 20px 20px 20px;
    border-top: 1px solid #f0f0f0;
    padding-top: 15px;
}

.btn-card-primary {
    display: block;
    width: 100%;
    padding: 10px;
    background: #437356;
    color: white;
    text-decoration: none;
    text-align: center;
    border-radius: 5px;
    font-weight: 600;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-card-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(67, 115, 86, 0.4);
    background: #1E4147;
}

.no-events {
    text-align: center;
    padding: 60px 30px;
    color: #666;
}

.no-events p {
    font-size: 1.2em;
    margin-bottom: 20px;
}

.btn-secondary {
    display: inline-block;
    padding: 10px 20px;
    background: #1E4147;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    transition: transform 0.2s, background 0.2s;
}

.btn-secondary:hover {
    background: #163137;
    transform: translateY(-2px);
}

/* EVENT DETAIL PAGE STYLES */

.event-detail-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    padding: 30px;
}

.event-detail-main {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.event-info-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 30px;
}

.event-header-section {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    margin-bottom: 30px;
    padding-bottom: 24px;
    border-bottom: 2px solid #e0e0e0;
}

.event-title-row {
    width: 100%;
    margin-bottom: 16px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    position: relative;
}

.activity-badge-corner {
    font-size: 0.75em;
    padding: 4px 10px;
    white-space: nowrap;
    margin-top: 4px;
}

.event-org-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.event-org-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.event-logo-container {
    flex-shrink: 0;
}

.event-logo {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.event-org-name {
    font-size: 1.5em;
    font-weight: 500;
    color: #666;
    margin: 0;
    line-height: 1.3;
}

.event-guide-name {
    font-size: 1em;
    font-weight: 400;
    color: #888;
    margin: 0;
    line-height: 1.3;
}

.event-name {
    font-size: calc(2em + 10px);
    font-weight: 700;
    color: #333;
    margin: 0;
    line-height: 1.2;
}

/* Dark mode support */
body.dark-mode .event-org-name {
    color: #b0b0b0;
}

body.dark-mode .event-name {
    color: #f0f0f0;
}

body.dark-mode .event-guide-name {
    color: #999;
}

body.dark-mode .event-header-section {
    border-bottom-color: #444;
}

.event-details-section h2 {
    color: #333;
    margin-bottom: 20px;
    font-size: 1.5em;
}

.detail-item {
    display: grid;
    grid-template-columns: 150px 1fr;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
    color: #555;
}

.detail-item:last-child {
    border-bottom: none;
}

.detail-item strong {
    color: #000000;
    font-weight: 600;
}

.map-direction-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: #437356;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 0.85em;
    font-weight: 500;
    transition: transform 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.map-direction-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.map-direction-btn svg {
    flex-shrink: 0;
}

.detail-item .badge {
    position: relative;
    display: inline-block;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 0.85em;
    font-weight: 600;
    top: 0;
    right: 0;
}

.share-section {
    background: #f9f9f9;
    border: 2px dashed #e0e0e0;
    border-radius: 8px;
    padding: 20px 24px;
}

.share-inner {
    display: flex;
    align-items: stretch;
    gap: 20px;
}

.share-left {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.share-section h3 {
    color: #333;
    margin-bottom: 14px;
    font-size: 1em;
}

.share-buttons {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.share-qr {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    border-left: 1px solid #e0e0e0;
    padding-left: 20px;
    flex-shrink: 0;
}

.share-qr canvas,
.share-qr img {
    border-radius: 6px;
    display: block;
}

.share-qr-label {
    font-size: 11px;
    color: #9ca3af;
    margin: 6px 0 0 0;
    text-align: center;
}

.share-btn {
    padding: 7px 14px;
    border: none;
    border-radius: 6px;
    font-size: 0.82em;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.3s;
}

.copy-btn {
    background: #437356;
    color: white;
}

.copy-btn:hover {
    background: #1E4147;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(67, 115, 86, 0.3);
}

.email-btn {
    background: #437356;
    color: white;
}

.email-btn:hover {
    background: #1E4147;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(67, 115, 86, 0.3);
}

.copy-message {
    color: #10b981;
    font-size: 0.9em;
    margin-top: 10px;
    font-weight: 600;
}

.event-detail-sidebar {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.event-detail-sidebar h3 {
    color: #333;
    margin-bottom: 0;
}

.event-map {
    width: 100%;
    height: 400px;
    border-radius: 8px;
    border: 1px solid #e0e0e0;
}

.route-info {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 8px;
    color: #555;
    font-size: 0.9em;
}

/* Register Button Styles */
.register-section {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

.btn-register {
    width: 100%;
    padding: 14px;
    background: #437356;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
}

.btn-register:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(67, 115, 86, 0.4);
    background: #1E4147;
}

.btn-register:active:not(:disabled) {
    transform: translateY(0);
}

.btn-register:disabled {
    background: #ccc;
    cursor: not-allowed;
    opacity: 0.6;
}

.btn-register.btn-disabled {
    background: #999;
    cursor: pointer;
    opacity: 0.8;
    pointer-events: auto;
}

.btn-register.btn-disabled:hover {
    background: #777;
    transform: translateY(-1px);
}

.btn-unregister {
    width: 100%;
    padding: 14px;
    background: #F34A53;
    color: white;
    border: none;
    border-radius: 6px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.btn-unregister:hover:not(:disabled) {
    background: #d13840;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(243, 74, 83, 0.35);
}

.btn-unregister:active:not(:disabled) {
    transform: translateY(0);
}

.btn-calendar {
    flex: 1;
    min-width: 200px;
    background: #437356;
    color: white;
    border: none;
    padding: 14px;
    border-radius: 6px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.3s;
}

.btn-calendar:hover {
    background: #1E4147;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(67, 115, 86, 0.35);
}

.btn-calendar:active {
    transform: translateY(0);
}

.register-message {
    margin-top: 15px;
    padding: 12px;
    border-radius: 6px;
    display: none;
    font-size: 0.95em;
}

.register-message.success {
    display: block;
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.register-message.error {
    display: block;
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.register-message.warning {
    display: block;
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

.event-actions {
    padding: 30px;
    border-top: 1px solid #e0e0e0;
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
}

.event-actions a {
    padding: 10px 20px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    transition: transform 0.2s;
}

.error-section {
    padding: 40px;
    text-align: center;
}

.error-section p {
    color: #e74c3c;
    margin-bottom: 20px;
    font-size: 1.1em;
}

@media (max-width: 768px) {
    header .header-top {
        flex-direction: column;
        text-align: center;
    }

    header h1 {
        font-size: 1.8em;
    }

    .header-nav {
        width: 100%;
        justify-content: center;
    }

    .content {
        grid-template-columns: 1fr;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .result-content {
        grid-template-columns: 1fr;
    }

    .result-card {
        padding: 20px;
    }

    .events-header {
        flex-direction: column;
        align-items: stretch;
    }

    .search-section {
        min-width: 100%;
    }

    .events-grid {
        grid-template-columns: 1fr;
    }

    .event-detail-content {
        grid-template-columns: 1fr;
        display: flex;
        flex-direction: column;
    }

    .event-detail-main {
        order: 1;
    }

    .event-detail-sidebar {
        order: 2;
    }

    #shareSection {
        order: 3;
    }

    .detail-item {
        grid-template-columns: 100px 1fr;
        font-size: 0.9em;
    }

    .event-actions {
        flex-direction: column;
    }

    .event-actions a {
        width: 100%;
        text-align: center;
    }
}


/* =========================================
   SITE FOOTER
   ========================================= */

.site-footer {
    background: #1E4147;
    color: #94a3b8;
    padding: 64px 20px 32px;
    margin-top: 64px;
}

.site-footer-inner {
    max-width: 1220px;
    margin: 0 auto;
}

.site-footer-grid {
    display: grid;
    grid-template-columns: 2fr 1.5fr 1.5fr 1.5fr 2fr;
    gap: 48px;
    padding-bottom: 48px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-col-heading {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #64748b;
    margin-bottom: 16px;
}

.footer-col ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 11px;
}

.footer-col ul li a {
    color: #cbd5e1;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.2s;
}

.footer-col ul li a:hover {
    color: #AAC789;
}

.footer-logo {
    display: block;
    margin-bottom: 20px;
}

.footer-logo img {
    height: 30px;
    opacity: 0.85;
}

.footer-social {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
}

.footer-social-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.07);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
}

.footer-social-icon:hover {
    background: #437356;
    color: #fff;
}

.footer-bottom {
    padding-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: #475569;
    flex-wrap: wrap;
    gap: 8px;
}

.footer-bottom a {
    color: #475569;
    text-decoration: none;
}

.footer-bottom a:hover {
    color: #AAC789;
}

/* Info pages (features, about, etc.) */
.info-page {
    max-width: 860px;
    margin: 0 auto;
    padding: 48px 24px 80px;
}

.info-page-hero {
    text-align: center;
    padding: 64px 0 48px;
}

.info-page-hero h1 {
    font-size: 42px;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 16px;
}

.info-page-hero p {
    font-size: 18px;
    color: #64748b;
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.6;
}

.info-section {
    margin-bottom: 48px;
}

.info-section h2 {
    font-size: 22px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 12px;
}

.info-section p, .info-section li {
    font-size: 15px;
    color: #475569;
    line-height: 1.75;
}

.info-section ul {
    padding-left: 20px;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.info-card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
    gap: 24px;
    margin-top: 16px;
}

.info-card {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 24px;
}

.info-card-icon {
    font-size: 28px;
    margin-bottom: 12px;
}

.info-card h3 {
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 6px;
}

.info-card p {
    font-size: 13px;
    color: #64748b;
    line-height: 1.6;
}

@media (max-width: 1024px) {
    .site-footer-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 640px) {
    .site-footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-col:last-child {
        grid-column: 1 / -1;
    }

    .info-page-hero h1 {
        font-size: 30px;
    }
}

/* =========================================
   COOKIE CONSENT BANNER
   ========================================= */

.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9998;
    padding: 0 16px 16px;
    pointer-events: none;
    transform: translateY(110%);
    transition: transform 0.45s cubic-bezier(0.34, 1.25, 0.64, 1);
}

.cookie-banner.cookie-banner-show {
    transform: translateY(0);
    pointer-events: auto;
}

.cookie-banner.cookie-banner-hide {
    transform: translateY(110%);
    pointer-events: none;
}

.cookie-banner-inner {
    max-width: 860px;
    margin: 0 auto;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 8px 40px rgba(15, 23, 42, 0.18), 0 2px 10px rgba(0, 0, 0, 0.06);
    padding: 22px 24px;
    display: flex;
    align-items: flex-start;
    gap: 18px;
    border: 1px solid rgba(121, 189, 143, 0.35);
}

.cookie-banner-icon {
    font-size: 36px;
    flex-shrink: 0;
    margin-top: 2px;
    animation: cookie-wobble 2.4s ease-in-out infinite;
    transform-origin: center bottom;
}

@keyframes cookie-wobble {
    0%, 100% { transform: rotate(-4deg); }
    50%       { transform: rotate(4deg); }
}

.cookie-banner-content {
    flex: 1;
    min-width: 0;
}

.cookie-banner-title {
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 6px;
    line-height: 1.35;
}

.cookie-banner-text {
    font-size: 13.5px;
    color: #475569;
    line-height: 1.55;
}

.cookie-banner-link {
    color: #437356;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
    margin-left: 4px;
}

.cookie-banner-link:hover {
    color: #1E4147;
    text-decoration: underline;
}

.cookie-banner-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex-shrink: 0;
    align-items: stretch;
    min-width: 155px;
}

.cookie-btn {
    border: none;
    border-radius: 10px;
    padding: 10px 18px;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
    white-space: nowrap;
    text-align: center;
}

.cookie-btn:active {
    transform: scale(0.96);
}

.cookie-btn-accept {
    background: #437356;
    color: #fff;
    box-shadow: 0 4px 14px rgba(67, 115, 86, 0.35);
}

.cookie-btn-accept:hover {
    background: #1E4147;
    box-shadow: 0 6px 18px rgba(67, 115, 86, 0.45);
}

.cookie-btn-decline {
    background: #f1f5f9;
    color: #64748b;
}

.cookie-btn-decline:hover {
    background: #e2e8f0;
    color: #475569;
}

/* Dark mode */
body.dark-mode .cookie-banner-inner {
    background: #1e293b;
    border-color: rgba(67, 115, 86, 0.25);
    box-shadow: 0 8px 40px rgba(0, 0, 0, 0.55), 0 2px 10px rgba(0, 0, 0, 0.3);
}

body.dark-mode .cookie-banner-title {
    color: #f1f5f9;
}

body.dark-mode .cookie-banner-text {
    color: #94a3b8;
}

body.dark-mode .cookie-btn-decline {
    background: #334155;
    color: #94a3b8;
}

body.dark-mode .cookie-btn-decline:hover {
    background: #475569;
    color: #cbd5e1;
}

/* Responsive */
@media (max-width: 640px) {
    .cookie-banner-inner {
        flex-direction: column;
        gap: 14px;
        padding: 18px 18px;
    }

    .cookie-banner-icon {
        font-size: 28px;
        margin-top: 0;
    }

    .cookie-banner-actions {
        flex-direction: row;
        width: 100%;
        min-width: unset;
    }

    .cookie-btn {
        flex: 1;
    }
}
