/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #3d7a7a;
    --primary-dark: #2d6565;
    --secondary-color: #5ba3a3;
    --text-color: #2c4a4a;
    --text-light: #5c7a7a;
    --bg-light: #f0f7f6;
    --border-color: #cde2e2;
    --accent-color: #3a8f8f;
    --marine-deep: #1e4545;
    --nav-red: #e53935;
    --nav-red-hover: #f44336;
    --site-bg-image: url("https://images.unsplash.com/photo-1544551763-46a013bb70d5?w=1920&q=90&fit=crop");
}

body {
    font-family: 'Oswald', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.7;
    color: var(--text-color);
    background-color: var(--marine-deep);
    background-image: var(--site-bg-image);
    background-position: top center;
    background-size: cover;
    background-repeat: no-repeat;
    background-attachment: fixed;
    min-height: 100vh;
    font-size: 16px;
    margin: 0;
    padding: 0;
}

body.homepage {
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Top nav */
.topnav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1.25rem;
    gap: 1rem;
    position: sticky;
    top: 0;
    z-index: 100;
    background: transparent;
    border-bottom: none;
}

.topnav-left,
.topnav-right {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 1rem;
    min-width: 0;
}
.topnav-left {
    justify-content: flex-start;
}
.topnav-right {
    justify-content: flex-end;
}

.topnav-logo {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    position: absolute;
    left: 50%;
    top: 6px;
    transform: translateX(-50%);
}

.topnav-social {
    color: var(--nav-red);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s, transform 0.2s;
    filter: drop-shadow(-1px -1px 0 #000) drop-shadow(1px -1px 0 #000) drop-shadow(-1px 1px 0 #000) drop-shadow(1px 1px 0 #000);
}
.topnav-social:hover {
    color: var(--nav-red-hover);
    transform: scale(1.18) translateY(-2px);
}
.topnav-social:active {
    transform: scale(1.3);
}
.topnav-social svg {
    display: block;
    width: 26px;
    height: 26px;
}

.topnav-brand {
    font-weight: 600;
    font-size: 1.1rem;
    color: #fff;
    text-decoration: none;
}

.topnav-toggle {
    display: none;
    width: 28px;
    height: 28px;
    padding: 0;
    border: none;
    background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23fff'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M4 6h16M4 12h16M4 18h16'/%3E%3C/svg%3E") center/24px no-repeat;
    cursor: pointer;
}

.topnav-links {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 1.5rem;
}

.topnav-links a {
    color: var(--nav-red);
    text-decoration: none;
    transition: color 0.2s, transform 0.2s;
}
.topnav-nav-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    filter: drop-shadow(-1px -1px 0 #000) drop-shadow(1px -1px 0 #000) drop-shadow(-1px 1px 0 #000) drop-shadow(1px 1px 0 #000);
}
.topnav-nav-icon svg {
    width: 26px;
    height: 26px;
    display: block;
}
.topnav-links a:hover {
    color: var(--nav-red-hover);
    transform: scale(1.18) translateY(-2px);
}
.topnav-links a:active {
    transform: scale(1.3);
}

.topnav-logo img {
    height: 58px;
    width: auto;
    display: block;
    transition: transform 0.2s ease;
}
.topnav-logo:hover img {
    transform: scale(1.12);
}

/* Legacy header (unused) */
header {
    display: none;
}

header.homepage-hidden {
    display: none;
}

header nav {
    padding: 1.2rem 0;
}

header nav .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

header h1 {
    font-size: 1.8rem;
    margin: 0;
    font-weight: 600;
    letter-spacing: -0.5px;
}

header h1 a {
    color: #fff;
    text-decoration: none;
    transition: opacity 0.3s;
}

header h1 a:hover {
    opacity: 0.9;
}

header ul {
    list-style: none;
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    margin: 0;
    padding: 0;
}

header ul li a {
    color: rgba(255, 255, 255, 0.95);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    padding: 0.5rem 0;
    transition: color 0.3s, border-bottom 0.3s;
    border-bottom: 2px solid transparent;
}

header ul li a:hover {
    color: #fff;
    border-bottom: 2px solid rgba(255, 255, 255, 0.8);
}

/* Main Content */
main {
    min-height: calc(100vh - 250px);
    padding: 3rem 0;
    background: transparent;
}

body.homepage main {
    min-height: 100vh;
    padding: 0;
}

body.homepage header {
    display: none;
}

/* Legacy (sidebar removed; top nav used) */
.mobile-menu-toggle {
    display: none;
    position: fixed;
    top: 15px;
    left: 15px;
    z-index: 1001;
    background: rgba(45, 101, 101, 0.95);
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 6px;
    width: 50px;
    height: 50px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    padding: 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

.mobile-menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background: #fff;
    border-radius: 2px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(8px, 8px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -7px);
}

/* Sidebar Styles */
.sidebar {
    flex: 0 0 280px;
    background: var(--primary-color);
    border-radius: 0;
    padding: 0;
    box-shadow: 2px 0 12px rgba(0,0,0,0.2);
    position: relative;
    min-height: 100vh;
    height: 100vh;
    overflow-y: auto;
    z-index: 10;
    border-right: 3px solid rgba(59, 130, 246, 0.5);
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease;
}

.sidebar::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 100vh;
    background: var(--primary-color);
    z-index: -1;
    pointer-events: none;
}

.sidebar-nav {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
    min-height: 100%;
}

.sidebar::-webkit-scrollbar {
    width: 6px;
}

.sidebar::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb {
    background: var(--secondary-color);
    border-radius: 3px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

.sidebar-nav h2 {
    font-size: 1.3rem;
    color: #ffffff;
    margin-bottom: 1.2rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid rgba(255, 255, 255, 0.3);
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.sidebar-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    flex: 1;
}

.sidebar-nav ul li {
    margin-bottom: 0.5rem;
}

.sidebar-nav ul li a {
    display: block;
    padding: 0.75rem 1rem;
    color: rgba(255, 255, 255, 0.9);
    text-decoration: none;
    border-radius: 6px;
    transition: all 0.3s ease;
    font-size: 0.95rem;
    border-left: 3px solid transparent;
}

.sidebar-nav ul li a:hover {
    background-color: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    border-left-color: var(--secondary-color);
    transform: translateX(5px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
    backdrop-filter: blur(5px);
}

/* Main */
.page-main {
    min-height: calc(100vh - 120px);
    padding: 2rem;
}

body.homepage .page-main {
    padding: 0;
    min-height: 100vh;
}

/* Landing: vertical stack of frosted cards */
.landing-page {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem 1.5rem;
}

.landing-stack {
    position: relative;
    z-index: 1;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-width: 560px;
    width: 100%;
    margin: 0 auto;
}

.feature-card {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1.25rem;
    padding: 1.25rem 1.75rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0.14) 50%, rgba(255, 255, 255, 0.18) 100%);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 9999px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: inset 0 -3px 12px rgba(0, 0, 0, 0.06);
    text-decoration: none;
    color: inherit;
    transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.feature-card:hover {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.3) 0%, rgba(255, 255, 255, 0.2) 50%, rgba(255, 255, 255, 0.26) 100%);
    transform: translateX(6px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2), inset 0 -3px 12px rgba(0, 0, 0, 0.06);
}

.lp-ovals {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
}
.lp-oval {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.22) 0%, rgba(255, 255, 255, 0.14) 50%, rgba(255, 255, 255, 0.18) 100%);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 9999px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    box-shadow: inset 0 -3px 12px rgba(0, 0, 0, 0.06);
    color: #fff;
    font-weight: 600;
    font-size: 0.95rem;
    text-decoration: none;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.lp-oval:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15), inset 0 -3px 12px rgba(0, 0, 0, 0.06);
}
.lp-oval--line {
    border-left: 4px solid #06c755;
}
.lp-oval--email {
    border-left: 4px solid #2c5f8d;
}

.feature-card--calendar { border-left: 4px solid var(--primary-color); }
.feature-card--map { border-left: 4px solid var(--secondary-color); }
.feature-card--sites { border-left: 4px solid var(--accent-color); }
.feature-card-icon {
    flex-shrink: 0;
    width: 52px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
}
.feature-card-icon img {
    height: 36px;
    width: auto;
    display: block;
}

.feature-card-body {
    flex: 1;
    min-width: 0;
}

.feature-card h3 {
    font-size: 1.2rem;
    font-weight: 600;
    color: #fff;
    margin: 0 0 0.25rem 0;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

.feature-card p {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.88);
    margin: 0 0 0.5rem 0;
    line-height: 1.45;
}

.feature-card-cta {
    font-size: 0.85rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.95);
    letter-spacing: 0.02em;
}

@media (max-width: 900px) {
    .topnav-toggle {
        display: block;
    }

    .topnav.open .topnav-links {
        display: flex;
    }

    .topnav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        background: inherit;
        padding: 1rem 1.25rem;
        gap: 0.5rem;
        border-bottom: 1px solid var(--border-color);
    }

    body.homepage .topnav-links {
        background: rgba(30, 69, 69, 0.98);
        border-bottom-color: rgba(255, 255, 255, 0.1);
    }
}

/* Photo Slideshow */
.photo-slideshow {
    position: relative;
    width: 100%;
    height: 100vh;
    min-height: 100vh;
    border-radius: 0;
    overflow: hidden;
    box-shadow: none;
}

.photo-slideshow .slide {
    overflow: hidden;
}

.photo-slideshow .slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1.5s ease-in-out;
}

.photo-slideshow .slide.active {
    opacity: 1;
}

.photo-slideshow .slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Hero info box on homepage */
.hero-info-box {
    position: absolute;
    top: calc(50% - 90px);
    left: 50%;
    transform: translate(-50%, -50%);
    max-height: calc(100vh - 200px);
    overflow-y: auto;
    background: rgba(30, 69, 69, 0.55);
    backdrop-filter: blur(10px);
    padding: 3rem 4rem;
    border-radius: 12px;
    text-align: center;
    z-index: 50;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.hero-info-box h1 {
    color: #fff;
    font-size: 3.5rem;
    font-weight: 700;
    margin: 0 0 1rem 0;
    letter-spacing: -1px;
}

.hero-info-box h2 {
    color: #fff;
    font-size: 1.5rem;
    font-weight: 400;
    margin: 0 0 1.5rem 0;
    line-height: 1.4;
}

.hero-info-box p {
    color: rgba(255, 255, 255, 0.95);
    font-size: 1.3rem;
    margin: 0 0 0.5rem 0;
    font-weight: 300;
}

.hero-info-box .conference-structure {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.hero-info-box .conference-structure p {
    font-size: 1rem;
    margin: 0.3rem 0;
    color: rgba(255, 255, 255, 0.9);
}

/* Collaborator Banner */
.collaborator-banner {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(8px);
    padding: 2rem 2rem;
    z-index: 100;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
}

.banner-content {
    display: flex;
    justify-content: space-around;
    align-items: center;
    gap: 3rem;
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 2rem;
}

.logo-item {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    max-width: 300px;
    height: 100px;
}

.logo-item img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    filter: grayscale(20%);
    opacity: 0.9;
    transition: opacity 0.3s ease, filter 0.3s ease;
}

.logo-item img:hover {
    opacity: 1;
    filter: grayscale(0%);
}

/* Map page: Taiwan map + dive site markers */
.map-page {
    padding: 0 0 3rem;
    max-width: 1000px;
    margin: 0 auto;
}
.map-intro {
    margin-bottom: 1rem;
    color: var(--text-color);
}
.taiwan-map-wrap {
    position: relative;
    width: 100%;
    max-width: 420px;
    margin: 0 auto 2rem;
    aspect-ratio: 700 / 985;
    min-height: 280px;
    background: transparent;
    border-radius: 12px;
    overflow: hidden;
}
.taiwan-map-base {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: center;
}
.taiwan-map-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 2;
}
.taiwan-map-overlay a {
    pointer-events: all;
    cursor: pointer;
    transition: transform 0.2s;
}
.taiwan-map-overlay a:hover {
    transform: scale(1.05);
}
.taiwan-map-overlay a:hover circle:first-of-type {
    fill: var(--accent-color);
}
.taiwan-map-overlay a text {
    pointer-events: none;
}
.map-site-link {
    position: absolute;
    top: 6%;
    left: 8%;
    z-index: 3;
    display: inline-block;
    padding: 0.5rem 0.85rem;
    background: #2c5f8d;
    color: #fff;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    border-radius: 8px;
    border: 2px solid #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
    white-space: nowrap;
}
.map-site-link:hover {
    background: #3d7a7a;
    color: #fff;
    border-color: #fff;
}

@media (min-width: 768px) {
    .taiwan-map-wrap {
        max-width: 520px;
    }
}

article {
    max-width: 1000px;
    margin: 0 auto;
}

article h1 {
    font-size: 2.8rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    font-weight: 700;
    line-height: 1.2;
    border-bottom: 3px solid var(--secondary-color);
    padding-bottom: 0.5rem;
}

article h2 {
    font-size: 2rem;
    margin-top: 2.5rem;
    margin-bottom: 1.2rem;
    color: var(--primary-dark);
    font-weight: 600;
}

article h3 {
    font-size: 1.5rem;
    margin-top: 1.8rem;
    margin-bottom: 0.8rem;
    color: var(--primary-dark);
    font-weight: 600;
}

article h4 {
    font-size: 1.2rem;
    margin-top: 1.5rem;
    margin-bottom: 0.6rem;
    color: var(--text-color);
    font-weight: 600;
}

article p {
    margin-bottom: 1.2rem;
    color: var(--text-color);
    line-height: 1.8;
}

article ul, article ol {
    margin-left: 2rem;
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

article li {
    margin-bottom: 0.6rem;
    color: var(--text-color);
}

article a {
    color: var(--accent-color);
    text-decoration: none;
    transition: color 0.3s;
}

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

article strong {
    color: var(--primary-dark);
    font-weight: 600;
}

.section-page .section-intro { margin-bottom: 2rem; }
.section-list { list-style: none; margin: 0; padding: 0; }
.section-list li { margin-bottom: 0.75rem; padding: 0.5rem 0; border-bottom: 1px solid var(--border-color); }
.section-list li:last-child { border-bottom: none; }
.section-list a { color: var(--accent-color); font-weight: 500; }
.section-list a:hover { color: var(--primary-dark); }
.section-list-desc { color: var(--text-light); font-size: 0.95rem; }

.section-dive-sites .section-intro,
.section-dive-sites .section-intro h2,
.section-dive-sites .section-intro p,
.section-dive-sites .section-list li,
.section-dive-sites .section-list-desc { color: rgba(255, 255, 255, 0.95); }
.section-dive-sites .section-list a { color: #a8e6ef; font-weight: 500; }
.section-dive-sites .section-list a:hover { color: #fff; }
.section-dive-sites .section-list li { border-bottom-color: rgba(255, 255, 255, 0.25); }

.dive-site-page { padding-bottom: 3rem; }
.dive-site-title { margin-bottom: 1.5rem; font-size: 2rem; color: var(--primary-dark); }
.dive-site-above, .dive-site-below { margin-bottom: 2.5rem; padding: 1.5rem; border-radius: 10px; }
.dive-site-above { background: linear-gradient(135deg, #f5f9e9 0%, #e8f4e4 100%); border-left: 4px solid #7cb342; }
.dive-site-below { background: linear-gradient(135deg, #e3f2fd 0%, #bbdefb 100%); border-left: 4px solid #1976d2; }
.dive-site-heading { font-size: 1.35rem; margin-bottom: 1rem; }
.dive-site-heading-above { color: #558b2f; }
.dive-site-heading-below { color: #1565c0; }
.dive-site-content p { margin-bottom: 0.75rem; }
.dive-site-content ul { margin-left: 1.5rem; margin-bottom: 0.75rem; }

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: #fff;
    padding: 4rem 2rem;
    text-align: center;
    margin: -3rem -20px 3rem -20px;
    border-radius: 0 0 8px 8px;
}

.hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
    color: #fff;
    border: none;
    padding: 0;
}

.hero p {
    font-size: 1.2rem;
    color: rgba(255, 255, 255, 0.95);
    max-width: 800px;
    margin: 0 auto;
}

/* Intro Section */
.intro {
    background: linear-gradient(to bottom, var(--bg-light) 0%, #ffffff 100%);
    padding: 2.5rem;
    border-radius: 8px;
    margin-bottom: 2.5rem;
    border-left: 4px solid var(--secondary-color);
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.intro h2 {
    margin-top: 0;
    color: var(--primary-dark);
}

/* Highlights Section */
.highlights {
    margin: 2.5rem 0;
}

.highlights ul {
    list-style-type: none;
    margin-left: 0;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.highlights li {
    padding: 1rem 1.5rem;
    background-color: var(--bg-light);
    border-radius: 6px;
    border-left: 3px solid var(--secondary-color);
    position: relative;
    transition: transform 0.2s, box-shadow 0.2s;
}

.highlights li:hover {
    transform: translateX(5px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.highlights li:before {
    content: "✓";
    position: absolute;
    left: 0.5rem;
    color: var(--secondary-color);
    font-weight: bold;
    font-size: 1.2rem;
}

/* Quick Links Grid */
.quick-links {
    margin-top: 3.5rem;
}

.quick-links h2 {
    text-align: center;
    margin-bottom: 2rem;
}

.links-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 1.5rem;
}

.link-card {
    background: linear-gradient(to bottom, #ffffff 0%, var(--bg-light) 100%);
    padding: 2rem;
    border-radius: 8px;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
    border: 2px solid var(--border-color);
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    display: block;
}

.link-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.15);
    border-color: var(--secondary-color);
}

.link-card h3 {
    color: var(--primary-color);
    margin-top: 0;
    margin-bottom: 0.8rem;
    font-size: 1.4rem;
}

.link-card p {
    color: var(--text-light);
    margin-bottom: 0;
    font-size: 0.95rem;
}

/* Info Boxes */
.info-box {
    background-color: var(--bg-light);
    padding: 1.5rem;
    border-radius: 6px;
    margin: 1.5rem 0;
    border-left: 4px solid var(--secondary-color);
}

.info-box h3 {
    margin-top: 0;
    color: var(--primary-dark);
}

/* Calendar page (dive calendar) */
.calendar-page { padding: 1rem 0 3rem; }
.calendar-wrap { display: flex; flex-direction: column; align-items: center; gap: 1rem; max-width: 100%; }
.calendar-month-controls { display: flex; align-items: center; justify-content: center; gap: 0.5rem; margin-bottom: 0.5rem; flex-wrap: wrap; }
.calendar-month-controls button { margin: 0; padding: 0.5rem 1rem; cursor: pointer; background: var(--primary-color); color: #fff; border: none; border-radius: 6px; font-size: 0.95rem; }
.calendar-month-controls button:hover { background: var(--primary-dark); }
.calendar-current-month { display: none; font-weight: bold; font-size: 0.9rem; color: var(--text-color); padding: 0 0.25rem; min-width: 8rem; text-align: center; }
.calendar-legend { display: flex; justify-content: center; gap: 1.25rem; margin-bottom: 1rem; flex-wrap: wrap; }
.calendar-legend .legend-item { display: flex; align-items: center; gap: 0.5rem; cursor: pointer; padding: 6px 12px; border-radius: 8px; background: rgba(255, 255, 255, 0.4); backdrop-filter: blur(8px); }
.calendar-legend .legend-item.disabled { opacity: 0.4; }
.calendar-legend .legend-color { width: 20px; height: 20px; border-radius: 4px; }
.calendar-legend .legend-color.course { background: #4a90e2; }
.calendar-legend .legend-color.dive { background: #2ecc71; }
.calendar-container { display: flex; flex-wrap: wrap; gap: 1rem; justify-content: center; max-width: 1200px; width: 100%; }
.calendar-page .month { border: 1px solid rgba(255, 255, 255, 0.4); border-radius: 10px; background: rgba(255, 255, 255, 0.4); backdrop-filter: blur(8px); padding: 8px; min-width: 250px; flex: 1; max-width: 100%; }
.calendar-page .month-name { text-align: center; font-weight: bold; font-size: 1.1rem; margin-bottom: 6px; color: var(--primary-dark); }
.calendar-page .days { display: grid; grid-template-columns: repeat(7, 1fr); gap: 1px; }
.calendar-page .day { border: 1px solid rgba(255, 255, 255, 0.4); font-size: 11px; cursor: pointer; background: rgba(255, 255, 255, 0.3); backdrop-filter: blur(4px); display: flex; flex-direction: column; height: 140px; position: relative; }
.calendar-page .day.has-multi-day { z-index: 2; }
.calendar-page .day-header { background: rgba(255, 255, 255, 0.25); border: 1px solid rgba(255, 255, 255, 0.4); font-weight: bold; display: flex; align-items: center; justify-content: center; height: 32px; }
.calendar-page .day .date { position: absolute; top: 2px; left: 2px; font-size: 0.75rem; font-weight: bold; z-index: 20; }
.calendar-page .event { position: absolute; left: 0; right: 0; height: 28px; margin: 2px 0; border-radius: 4px; font-size: 0.85rem; color: #fff; padding: 0; cursor: pointer; z-index: 10; overflow: visible; }
.calendar-page .event > span { position: absolute; left: 4px; top: 0; bottom: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; line-height: 28px; cursor: pointer; color: #fff; }
.calendar-page .event.course { background: #4a90e2; }
.calendar-page .event.dive { background: #2ecc71; }
.calendar-page .event.featured { background: #ffd700; border: 2px solid #c0c0c0; }
.calendar-page .event.featured > span { color: #5a5a5a; }
.calendar-page .event.hidden { display: none; }
.calendar-page .event.multi-day.start { border-top-left-radius: 3px; border-bottom-left-radius: 3px; border-top-right-radius: 0; border-bottom-right-radius: 0; left: -1px; right: -3px; z-index: 15; }
.calendar-page .event.multi-day.middle { border-radius: 0; left: -3px; right: -3px; z-index: 15; }
.calendar-page .event.multi-day.end { border-top-right-radius: 3px; border-bottom-right-radius: 3px; border-top-left-radius: 0; border-bottom-left-radius: 0; left: -3px; right: -1px; z-index: 15; }

.calendar-modal { display: none; position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 85%; max-width: 450px; background: linear-gradient(135deg, #e0f7fa 0%, #b2ebf2 100%); border-radius: 16px; padding: 2rem; z-index: 9999; box-shadow: 0 10px 40px rgba(0,0,0,0.2); }
.calendar-modal .calendar-modal-close { position: absolute; top: 12px; right: 12px; background: rgba(0,0,0,0.05); border: none; font-size: 24px; line-height: 1; color: #666; cursor: pointer; width: 32px; height: 32px; display: flex; align-items: center; justify-content: center; border-radius: 50%; padding: 0; }
.calendar-modal .calendar-modal-close:hover { background: rgba(0,0,0,0.1); color: #333; }
.calendar-modal h3 { margin: 0 0 0.75rem 0; font-size: 1.75rem; font-weight: 700; color: #1a1a1a; padding-right: 40px; line-height: 1.3; }
.calendar-modal-content { display: flex; flex-direction: column; gap: 1.25rem; }
.calendar-modal-item { display: flex; flex-direction: column; }
.calendar-modal-item #detailDate, .calendar-modal-item #detailPrice { font-size: 0.9rem; color: #000; }
.calendar-modal-btn { width: 100%; padding: 14px 24px; border: none; border-radius: 10px; font-size: 1rem; font-weight: 700; cursor: pointer; text-align: center; text-decoration: none; text-transform: uppercase; letter-spacing: 1px; box-shadow: 0 4px 15px rgba(0,0,0,0.2); transition: transform 0.2s, box-shadow 0.2s; }
.calendar-modal-btn:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,0.3); }
.calendar-details-btn { background: linear-gradient(135deg, var(--secondary-color) 0%, var(--primary-color) 100%); color: #fff; }
.calendar-book-btn { background: linear-gradient(135deg, var(--marine-deep) 0%, var(--primary-dark) 100%); color: #fff; }
.calendar-modal #detailLink.hidden, .calendar-modal #bookLink.hidden { display: none; }

/* Calendar mobile (list view) */
@media (max-width: 768px) {
  .calendar-page { padding: 0.5rem 0.25rem 2rem; }
  .calendar-month-controls { width: 100%; justify-content: space-between; margin-bottom: 0.5rem; }
  .calendar-month-controls .calendar-current-month { display: block; }
  .calendar-month-controls .calendar-btn-label { display: none; }
  .calendar-month-controls button { min-width: 44px; min-height: 44px; padding: 8px; font-size: 1.2rem; border-radius: 8px; display: flex; align-items: center; justify-content: center; }
  .calendar-legend { gap: 8px; margin-bottom: 8px; }
  .calendar-legend .legend-item { padding: 6px 10px; min-height: 36px; border: 1px solid rgba(255, 255, 255, 0.4); border-radius: 6px; background: rgba(255, 255, 255, 0.4); backdrop-filter: blur(8px); }
  .calendar-legend .legend-color { width: 16px; height: 16px; }
  .calendar-legend .legend-item span:not(.legend-color) { font-size: 0.8rem; font-weight: bold; }
  .calendar-container { flex-direction: column; gap: 0; max-width: 100%; }
  .calendar-page .month { padding: 0; min-width: 0; width: 100%; }
  .calendar-page .month-name { display: none; }
  .calendar-page .days { display: flex; flex-direction: column; gap: 0; position: relative; }
  .calendar-page .day,
  .calendar-page .day-header { display: none !important; }
  .calendar-page .day-row { display: flex; flex-direction: row; height: 60px; min-height: 60px; border-bottom: 1px solid rgba(255, 255, 255, 0.3); background: rgba(255, 255, 255, 0.3); backdrop-filter: blur(4px); padding: 8px 2px; gap: 12px; align-items: stretch; position: relative; box-sizing: border-box; overflow: visible; }
  .calendar-page .day-row:last-child { border-bottom: none; }
  .calendar-page .day-info { flex: 0 0 60px; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; padding-top: 4px; }
  .calendar-page .day-number { font-size: 1.2rem; font-weight: bold; color: var(--text-color); line-height: 1.2; }
  .calendar-page .day-name { font-size: 0.7rem; color: var(--text-light); text-transform: uppercase; margin-top: 2px; }
  .calendar-page .day-events { flex: 1; min-width: 0; display: flex; flex-direction: row; gap: 4px; min-height: 44px; overflow-x: auto; overflow-y: hidden; align-items: stretch; -webkit-overflow-scrolling: touch; box-sizing: border-box; }
  .calendar-page .day-events.empty { justify-content: center; color: var(--text-light); font-size: 0.85rem; font-style: italic; }
  .calendar-page .event-slot-empty { width: 60px; min-width: 50px; flex-shrink: 0; }
  .calendar-page .day-row .event { position: static; flex: 0 0 auto; width: 60px; min-width: 50px; min-height: 44px; margin: 0 0 4px 0; padding: 6px 4px; display: flex; flex-direction: column; align-items: center; justify-content: center; border-radius: 6px; font-size: 0.7rem; border: 1px solid rgba(0,0,0,0.1); box-shadow: 0 1px 3px rgba(0,0,0,0.1); box-sizing: border-box; overflow: hidden; }
  .calendar-page .day-row .event > span { position: static; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; word-break: break-word; font-size: 0.7rem; line-height: 1.2; text-align: center; max-width: 100%; }
  .calendar-page .multi-day-bar { position: absolute; z-index: 2; cursor: pointer; display: flex; flex-direction: column; padding: 6px 4px; box-sizing: border-box; border: 1px solid rgba(0,0,0,0.1); box-shadow: 0 1px 3px rgba(0,0,0,0.1); color: #fff; font-size: 0.7rem; overflow: hidden; }
  .calendar-page .multi-day-bar.course { background: #4a90e2; }
  .calendar-page .multi-day-bar.dive { background: #2ecc71; }
  .calendar-page .multi-day-bar.featured { background: #ffd700; border: 2px solid #c0c0c0; color: #5a5a5a; }
  .calendar-page .multi-day-bar.hidden { display: none; }
  .calendar-page .multi-day-bar-title { overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; word-break: break-word; line-height: 1.2; text-align: center; }
}

/* Contact form */
.contact-form {
    max-width: 520px;
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.contact-form label {
    font-weight: 600;
    color: var(--primary-dark);
    font-size: 0.95rem;
}

.contact-form input,
.contact-form textarea {
    padding: 0.65rem 0.85rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 1rem;
    font-family: inherit;
    background: #fff;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--secondary-color);
}

.contact-form button {
    margin-top: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.contact-form button:hover {
    background: var(--primary-dark);
}

/* Tables */
table {
    width: 100%;
    border-collapse: collapse;
    margin: 1.5rem 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

table th {
    background-color: var(--primary-color);
    color: #fff;
    padding: 1rem;
    text-align: left;
    font-weight: 600;
}

table td {
    padding: 0.8rem 1rem;
    border-bottom: 1px solid var(--border-color);
}

table tr:hover {
    background-color: var(--bg-light);
}

/* Footer */
footer {
    background: rgba(30, 69, 69, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #e8f0f0;
    padding: 2.5rem 0;
    margin-top: 4rem;
    text-align: center;
}

footer .container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

footer p {
    margin: 0;
    color: rgba(255, 255, 255, 0.8);
}

footer a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: color 0.3s;
}

footer a:hover {
    color: #7ebdbd;
    text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .page-layout,
    .homepage-layout {
        flex-direction: column;
        gap: 0;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .sidebar {
        flex: 1;
        position: fixed;
        top: 0;
        left: 0;
        width: 280px;
        max-width: 85%;
        min-height: 100vh;
        min-height: 100dvh;
        height: 100vh;
        height: 100dvh;
        bottom: 0;
        transform: translateX(-100%);
        z-index: 1000;
        box-shadow: 4px 0 20px rgba(0,0,0,0.3);
        transition: transform 0.3s ease;
        padding-top: 70px; /* Add top padding to avoid hamburger button */
        background: var(--primary-color) !important;
    }
    
    .sidebar::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        height: 100vh;
        height: 100dvh;
        background: var(--primary-color);
        z-index: -1;
        pointer-events: none;
    }

    .sidebar.open {
        transform: translateX(0);
    }

    /* Overlay when sidebar is open */
    .sidebar-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.6);
        z-index: 999;
        backdrop-filter: blur(2px);
    }

    .sidebar-overlay.active {
        display: block;
    }

    .homepage-main {
        width: 100%;
        margin-left: 0;
    }

    /* Add top padding to page content to avoid hamburger button when sidebar is closed */
    .page-main {
        padding-top: 80px;
    }

    .photo-slideshow {
        width: 100%;
    }

    .photo-slideshow {
        height: 100vh;
        min-height: 100vh;
    }

    .hero-info-box {
        padding: 2.5rem 3rem;
        max-width: 85%;
    }

    .hero-info-box h1 {
        font-size: 3rem;
    }

    .hero-info-box h2 {
        font-size: 1.3rem;
    }

    .hero-info-box p {
        font-size: 1.2rem;
    }

    .hero-info-box .conference-structure p {
        font-size: 1rem;
    }

    .collaborator-banner {
        padding: 1rem 1.5rem;
    }

    .banner-content {
        gap: 3rem;
        padding: 0 1rem;
    }

    .logo-item {
        max-width: 220px;
        height: 80px;
    }
}

@media (max-width: 768px) {
    header nav .container {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }

    header h1 {
        font-size: 1.5rem;
    }

    header ul {
        justify-content: center;
        gap: 1rem;
        font-size: 0.9rem;
    }

    .page-layout,
    .homepage-layout {
        padding: 0;
        position: relative;
    }

    .photo-slideshow {
        height: 100vh;
        min-height: 100vh;
    }

    .hero-info-box {
        padding: 1.5rem 1.5rem;
        max-width: 95%;
        margin: 0 auto;
    }

    .hero-info-box h1 {
        font-size: 2rem;
        line-height: 1.1;
    }

    .hero-info-box h2 {
        font-size: 1rem;
        line-height: 1.3;
    }

    .hero-info-box p {
        font-size: 0.95rem;
        margin-bottom: 0.8rem;
    }

    .hero-info-box .conference-structure {
        margin-top: 1rem;
        padding-top: 0.8rem;
    }

    .hero-info-box .conference-structure p {
        font-size: 0.85rem;
        margin: 0.25rem 0;
    }

    .collaborator-banner {
        padding: 1rem 0.5rem;
    }

    .banner-content {
        flex-direction: row;
        gap: 1rem;
        padding: 0 0.5rem;
        justify-content: space-around;
        align-items: center;
    }

    .logo-item {
        max-width: 140px;
        min-height: 60px;
        height: auto;
        flex: 1;
        display: flex;
        align-items: center;
    }

    .sidebar-nav h2 {
        font-size: 1.1rem;
    }

    .sidebar-nav ul li a {
        padding: 0.6rem 0.8rem;
        font-size: 0.9rem;
        -webkit-tap-highlight-color: rgba(255, 255, 255, 0.2);
        touch-action: manipulation;
    }

    .sidebar-nav ul li {
        min-height: 44px;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    article h1 {
        font-size: 2rem;
    }

    article h2 {
        font-size: 1.6rem;
    }

    .links-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .highlights ul {
        grid-template-columns: 1fr;
    }

    main {
        padding: 2rem 0;
    }

    .intro {
        padding: 1.5rem;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    header ul {
        flex-direction: column;
        gap: 0.5rem;
    }

    article h1 {
        font-size: 1.75rem;
    }

    .hero-info-box {
        padding: 1.2rem 1rem;
        max-width: 98%;
    }

    .hero-info-box h1 {
        font-size: 1.75rem;
    }

    .hero-info-box h2 {
        font-size: 0.9rem;
    }

    .hero-info-box p {
        font-size: 0.85rem;
    }

    .hero-info-box .conference-structure p {
        font-size: 0.75rem;
    }

    .collaborator-banner {
        padding: 0.8rem 0.5rem;
    }

    .banner-content {
        flex-direction: row;
        gap: 0.5rem;
        padding: 0 0.25rem;
        justify-content: space-around;
        align-items: center;
    }

    .logo-item {
        max-width: 120px;
        min-height: 55px;
        height: auto;
        flex: 1;
        display: flex;
        align-items: center;
    }

    /* Improve image loading on mobile */
    .photo-slideshow img {
        object-fit: cover;
        width: 100%;
        height: 100%;
    }

    /* Better spacing for conference info on very small screens */
    .hero-info-box {
        line-height: 1.4;
    }

    .sidebar {
        width: 260px;
        padding: 1rem;
        padding-top: 65px; /* Add top padding to avoid hamburger button */
        min-height: 100vh;
        min-height: 100dvh;
        height: 100vh;
        height: 100dvh;
        bottom: 0;
        background: var(--primary-color) !important;
    }
    
    .sidebar::after {
        content: '';
        position: absolute;
        bottom: 0;
        left: 0;
        right: 0;
        height: 100vh;
        height: 100dvh;
        background: var(--primary-color);
        z-index: -1;
        pointer-events: none;
    }

    /* Overlay when sidebar is open */
    .sidebar.open::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        right: 0;
        bottom: 0;
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
    }

    .sidebar-nav h2 {
        font-size: 1rem;
        margin-bottom: 1rem;
    }

    .sidebar-nav ul li a {
        padding: 0.5rem 0.7rem;
        font-size: 0.85rem;
        -webkit-tap-highlight-color: rgba(255, 255, 255, 0.2);
        touch-action: manipulation;
    }

    /* Improve touch targets on mobile */
    .sidebar-nav ul li {
        min-height: 44px;
    }

    /* Prevent text selection on mobile menu toggle */
    .mobile-menu-toggle,
    .mobile-menu-toggle span {
        user-select: none;
        -webkit-user-select: none;
    }

    .mobile-menu-toggle {
        width: 45px;
        height: 45px;
        top: 10px;
        left: 10px;
    }
}
