/* ============================================
   bada.cafe - Underwater Patisserie
   ============================================ */

/* --- Color Reference ---
   #0A1628 Abyssal Navy
   #122240 Midnight Trench
   #1B3A5C Twilight Zone
   #C8935A Tarnished Brass
   #E8D5B7 Aged Cream
   #C4B8A8 Weathered Parchment
   #7EC8C8 Deep Teal Glow
   #4AEACC Phosphor Green
   #D4764E Coral Ember
   #8B6B3D Brass Shadow
   #FFFFFF Sea Glass (used at low opacity)
--- */

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

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    background-color: #0A1628;
    color: #C4B8A8;
    font-family: 'Lora', serif;
    font-size: clamp(1rem, 1.8vw, 1.2rem);
    line-height: 1.75;
    letter-spacing: 0.01em;
    overflow-x: hidden;
    position: relative;
}

/* --- Grain Overlay --- */
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    mix-blend-mode: overlay;
    opacity: 0.06;
    z-index: 9999;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='1'/%3E%3C/svg%3E");
    background-size: 256px 256px;
    background-repeat: repeat;
}

/* --- Depth Gauge --- */
.depth-gauge {
    position: fixed;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1000;
    opacity: 0;
    transition: opacity 1s ease 2s;
}

.depth-gauge.visible {
    opacity: 1;
}

.depth-gauge-frame {
    width: 40px;
    height: 200px;
    background: linear-gradient(180deg, #C8935A 0%, #8B6B3D 100%);
    border-radius: 6px;
    padding: 3px;
    box-shadow:
        inset 0 1px 0 rgba(232, 213, 183, 0.4),
        inset 0 -1px 0 rgba(139, 107, 61, 0.6),
        0 4px 12px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(200, 147, 90, 0.3);
    position: relative;
}

.depth-gauge-glass {
    width: 100%;
    height: 100%;
    background: linear-gradient(180deg, #122240 0%, #0A1628 100%);
    border-radius: 4px;
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.5);
}

.depth-gauge-glass::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 40%;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), transparent);
    border-radius: 4px 4px 0 0;
    pointer-events: none;
}

.depth-gauge-markers {
    position: absolute;
    top: 10px;
    bottom: 10px;
    right: 4px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.depth-marker {
    display: block;
    width: 8px;
    height: 1px;
    background-color: #E8D5B7;
    opacity: 0.2;
}

.depth-gauge-needle {
    position: absolute;
    left: 6px;
    top: 10px;
    width: 20px;
    height: 2px;
    background: linear-gradient(90deg, #D4764E, #C8935A);
    border-radius: 1px;
    box-shadow: 0 0 6px rgba(212, 118, 78, 0.5);
    transition: top 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.depth-label {
    position: absolute;
    font-family: 'DM Sans', sans-serif;
    font-size: 0.55rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #7EC8C8;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
}

.depth-label-top {
    top: -18px;
}

.depth-label-bottom {
    bottom: -18px;
}

/* --- Bioluminescent Particles --- */
.particles {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 100;
    opacity: 0;
    transition: opacity 1s ease;
}

.particles.active {
    opacity: 1;
}

.particle {
    position: absolute;
    border-radius: 50%;
    opacity: 0;
}

.p1 { width: 3px; height: 3px; background: #4AEACC; left: 10%; top: 20%; animation: floatParticle1 12s infinite ease-in-out; }
.p2 { width: 5px; height: 5px; background: #7EC8C8; left: 25%; top: 40%; animation: floatParticle2 10s infinite ease-in-out; }
.p3 { width: 2px; height: 2px; background: #4AEACC; left: 45%; top: 60%; animation: floatParticle3 14s infinite ease-in-out; }
.p4 { width: 4px; height: 4px; background: #7EC8C8; left: 70%; top: 30%; animation: floatParticle1 11s infinite ease-in-out 2s; }
.p5 { width: 3px; height: 3px; background: #4AEACC; left: 85%; top: 55%; animation: floatParticle2 13s infinite ease-in-out 1s; }
.p6 { width: 6px; height: 6px; background: #7EC8C8; left: 15%; top: 75%; animation: floatParticle3 9s infinite ease-in-out 3s; }
.p7 { width: 2px; height: 2px; background: #4AEACC; left: 55%; top: 15%; animation: floatParticle1 15s infinite ease-in-out 4s; }
.p8 { width: 4px; height: 4px; background: #7EC8C8; left: 35%; top: 85%; animation: floatParticle2 8s infinite ease-in-out 2s; }
.p9 { width: 3px; height: 3px; background: #4AEACC; left: 65%; top: 45%; animation: floatParticle3 11s infinite ease-in-out 5s; }
.p10 { width: 5px; height: 5px; background: #7EC8C8; left: 80%; top: 70%; animation: floatParticle1 10s infinite ease-in-out 1s; }
.p11 { width: 2px; height: 2px; background: #4AEACC; left: 5%; top: 50%; animation: floatParticle2 14s infinite ease-in-out 3s; }
.p12 { width: 4px; height: 4px; background: #4AEACC; left: 90%; top: 10%; animation: floatParticle3 12s infinite ease-in-out 2s; }
.p13 { width: 3px; height: 3px; background: #7EC8C8; left: 40%; top: 90%; animation: floatParticle1 9s infinite ease-in-out 4s; }
.p14 { width: 5px; height: 5px; background: #4AEACC; left: 60%; top: 25%; animation: floatParticle2 11s infinite ease-in-out 1s; }
.p15 { width: 2px; height: 2px; background: #7EC8C8; left: 20%; top: 65%; animation: floatParticle3 13s infinite ease-in-out 5s; }
.p16 { width: 3px; height: 3px; background: #4AEACC; left: 75%; top: 80%; animation: floatParticle1 10s infinite ease-in-out 3s; }
.p17 { width: 4px; height: 4px; background: #7EC8C8; left: 50%; top: 35%; animation: floatParticle2 12s infinite ease-in-out 2s; }
.p18 { width: 6px; height: 6px; background: #4AEACC; left: 30%; top: 10%; animation: floatParticle3 8s infinite ease-in-out 4s; }

@keyframes floatParticle1 {
    0%   { transform: translate(0, 0); opacity: 0; }
    15%  { opacity: 0.6; }
    50%  { transform: translate(30px, -40px); opacity: 0.3; }
    85%  { opacity: 0.5; }
    100% { transform: translate(-20px, 20px); opacity: 0; }
}

@keyframes floatParticle2 {
    0%   { transform: translate(0, 0); opacity: 0; }
    20%  { opacity: 0.5; }
    50%  { transform: translate(-25px, 35px); opacity: 0.2; }
    80%  { opacity: 0.7; }
    100% { transform: translate(15px, -25px); opacity: 0; }
}

@keyframes floatParticle3 {
    0%   { transform: translate(0, 0); opacity: 0; }
    10%  { opacity: 0.4; }
    40%  { transform: translate(20px, 30px); opacity: 0.6; }
    70%  { transform: translate(-30px, -10px); opacity: 0.2; }
    100% { transform: translate(10px, -20px); opacity: 0; }
}

/* --- Grotto Sections --- */
.grotto {
    min-height: 100vh;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    perspective: 1200px;
    overflow: hidden;
}

.grotto-surface {
    background: linear-gradient(180deg, #1B3A5C 0%, #122240 40%, #0A1628 100%);
}

.grotto-tasting {
    background: linear-gradient(180deg, #122240 0%, #0A1628 100%);
}

.grotto-archive {
    background: linear-gradient(180deg, #0A1628 0%, #0A1628 50%, #091220 100%);
}

.grotto-cellar {
    background: linear-gradient(180deg, #091220 0%, #070E1A 100%);
}

.grotto-abyss {
    background: linear-gradient(180deg, #070E1A 0%, #050B14 100%);
}

.grotto-final {
    min-height: 50vh;
    background: #050B14;
}

.grotto-content {
    width: 100%;
    max-width: 900px;
    margin: 0 auto;
    padding: 4rem 2rem;
    position: relative;
    z-index: 2;
}

/* --- Water Surface Effect --- */
.water-surface-effect {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 120px;
    background:
        radial-gradient(ellipse 80% 50% at 20% 0%, rgba(27, 58, 92, 0.6) 0%, transparent 60%),
        radial-gradient(ellipse 60% 40% at 60% 0%, rgba(27, 58, 92, 0.4) 0%, transparent 50%),
        radial-gradient(ellipse 90% 60% at 80% 0%, rgba(18, 34, 64, 0.5) 0%, transparent 55%);
    animation: causticShift 8s ease-in-out infinite alternate;
    z-index: 1;
}

@keyframes causticShift {
    0% {
        background-position: 0% 0%, 10% 0%, 5% 0%;
    }
    100% {
        background-position: 10% 0%, -5% 0%, -10% 0%;
    }
}

/* --- Caustics Overlay (surface grotto) --- */
.caustics-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    opacity: 0.08;
    background:
        radial-gradient(ellipse 30% 20% at 30% 30%, rgba(126, 200, 200, 0.3), transparent),
        radial-gradient(ellipse 25% 25% at 70% 50%, rgba(126, 200, 200, 0.2), transparent),
        radial-gradient(ellipse 35% 15% at 50% 70%, rgba(126, 200, 200, 0.25), transparent);
    animation: causticDrift 12s ease-in-out infinite alternate;
}

@keyframes causticDrift {
    0% {
        background-position: 0% 0%, 0% 0%, 0% 0%;
        opacity: 0.06;
    }
    50% {
        opacity: 0.1;
    }
    100% {
        background-position: 5% 3%, -3% 2%, 4% -2%;
        opacity: 0.06;
    }
}

/* --- Skeleton Loading --- */
.skeleton-group {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    z-index: 5;
    transition: opacity 0.8s ease;
}

.skeleton-group.hidden {
    opacity: 0;
    pointer-events: none;
}

.skeleton-title {
    width: 280px;
    height: 40px;
    border: 1.5px solid #C8935A;
    border-radius: 4px;
    animation: pulseBrass 3s ease-in-out infinite;
}

.skeleton-line {
    width: 200px;
    height: 2px;
    background: #C8935A;
    animation: pulseBrass 3s ease-in-out infinite 0.3s;
}

.skeleton-line-short {
    width: 140px;
}

.skeleton-case {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    z-index: 5;
    transition: opacity 0.8s ease;
    background: rgba(18, 34, 64, 0.5);
    border-radius: 16px;
}

.skeleton-case.hidden {
    opacity: 0;
    pointer-events: none;
}

.skeleton-circle {
    width: 50px;
    height: 50px;
    border: 1.5px solid #C8935A;
    border-radius: 50%;
    animation: pulseBrass 3s ease-in-out infinite;
}

.skeleton-case .skeleton-line {
    width: 60%;
}

.skeleton-case .skeleton-line-short {
    width: 40%;
}

@keyframes pulseBrass {
    0%   { opacity: 0.3; }
    50%  { opacity: 0.7; }
    100% { opacity: 0.3; }
}

/* --- Surface Content --- */
.surface-content {
    text-align: center;
    position: relative;
    z-index: 3;
    opacity: 0;
    transition: opacity 1s ease;
}

.surface-content.visible {
    opacity: 1;
}

.site-title {
    font-family: 'Libre Baskerville', serif;
    font-weight: 400;
    font-style: italic;
    font-size: clamp(3rem, 8vw, 6rem);
    color: #E8D5B7;
    letter-spacing: 0.03em;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
    transform: translateY(-60px);
    animation: sinkTitle 2s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
    animation-delay: 1.8s;
    opacity: 0;
}

@keyframes sinkTitle {
    0% {
        transform: translateY(-60px);
        opacity: 0;
    }
    100% {
        transform: translateY(0);
        opacity: 1;
    }
}

.site-subtitle {
    font-family: 'Lora', serif;
    font-size: clamp(0.9rem, 2vw, 1.3rem);
    color: #C4B8A8;
    margin-top: 1rem;
    opacity: 0;
    animation: fadeIn 1s ease forwards;
    animation-delay: 3s;
}

.descend-hint {
    margin-top: 3rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    opacity: 0;
    animation: fadeIn 1s ease forwards;
    animation-delay: 3.5s;
}

.descend-label {
    font-family: 'DM Sans', sans-serif;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #7EC8C8;
}

.descend-chevron {
    animation: bobDown 2s ease-in-out infinite;
}

@keyframes bobDown {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(6px); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* --- Grotto Headers --- */
.grotto-header {
    text-align: center;
    margin-bottom: 3rem;
}

.grotto-title {
    font-family: 'Libre Baskerville', serif;
    font-weight: 400;
    font-style: italic;
    font-size: clamp(2.2rem, 5vw, 4rem);
    color: #E8D5B7;
    letter-spacing: 0.03em;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
    margin-bottom: 1rem;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.grotto-title.revealed {
    opacity: 1;
    transform: translateY(0);
}

.section-divider {
    width: 100%;
    max-width: 400px;
    height: 20px;
    display: block;
    margin: 0 auto;
    filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.3));
    opacity: 0;
    transition: opacity 0.8s ease 0.2s;
}

.section-divider.revealed {
    opacity: 1;
}

/* --- Display Cases --- */
.display-cases,
.archive-shelves,
.cellar-chambers,
.abyss-shelves {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
    margin-bottom: 2rem;
}

@media (max-width: 768px) {
    .display-cases,
    .archive-shelves,
    .cellar-chambers,
    .abyss-shelves {
        grid-template-columns: 1fr;
    }
}

.display-case {
    position: relative;
    border-radius: 16px;
    padding: 2rem;
    min-height: 320px;
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.4s ease;
    opacity: 0;
    transform: translateY(30px);
}

.display-case.revealed {
    opacity: 1;
    transform: translateY(0);
}

.case-left {
    transform: rotate(-1deg) translateY(30px);
}

.case-left.revealed {
    transform: rotate(-1deg) translateY(0);
}

.case-right {
    transform: rotate(1deg) translateY(30px);
}

.case-right.revealed {
    transform: rotate(1deg) translateY(0);
}

.display-case:hover {
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
}

.case-left:hover {
    transform: rotate(-1deg) translateY(-4px);
}

.case-right:hover {
    transform: rotate(1deg) translateY(-4px);
}

/* Case Glass Effect - uses #FFFFFF at 8% opacity for sea glass highlights */
.case-glass {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(18, 34, 64, 0.8), rgba(10, 22, 40, 0.9));
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.08),
        inset 0 -1px 0 rgba(0, 0, 0, 0.3),
        0 4px 16px rgba(0, 0, 0, 0.3),
        0 0 0 1px rgba(200, 147, 90, 0.15);
    z-index: 0;
}

/* Sea Glass highlight token */
.case-glass::after {
    content: '';
    position: absolute;
    top: 0;
    left: 10%;
    width: 80%;
    height: 1px;
    background: #FFFFFF;
    opacity: 0.08;
}

/* Condensation Effect */
.case-condensation {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 40%;
    border-radius: 16px 16px 0 0;
    background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(255, 255, 255, 0.03), transparent);
    pointer-events: none;
    z-index: 1;
    transition: opacity 0.4s ease;
}

.display-case:hover .case-condensation {
    background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(255, 255, 255, 0.08), transparent);
}

/* Brass Corner Fittings */
.case-corner {
    position: absolute;
    width: 20px;
    height: 20px;
    z-index: 2;
    transition: box-shadow 0.4s ease;
}

.case-corner-tl {
    top: 6px;
    left: 6px;
    border-top: 2px solid #C8935A;
    border-left: 2px solid #C8935A;
    border-radius: 4px 0 0 0;
}

.case-corner-tr {
    top: 6px;
    right: 6px;
    border-top: 2px solid #C8935A;
    border-right: 2px solid #C8935A;
    border-radius: 0 4px 0 0;
}

.case-corner-bl {
    bottom: 6px;
    left: 6px;
    border-bottom: 2px solid #C8935A;
    border-left: 2px solid #C8935A;
    border-radius: 0 0 0 4px;
}

.case-corner-br {
    bottom: 6px;
    right: 6px;
    border-bottom: 2px solid #C8935A;
    border-right: 2px solid #C8935A;
    border-radius: 0 0 4px 0;
}

.display-case:hover .case-corner {
    box-shadow: 0 0 8px rgba(200, 147, 90, 0.4);
}

/* Case Interior */
.case-interior {
    position: relative;
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1rem;
}

.case-content {
    opacity: 0;
    transition: opacity 0.6s ease;
}

.case-content.visible {
    opacity: 1;
}

.pastry-icon,
.folio-icon,
.vessel-icon,
.ingredient-icon {
    margin-bottom: 0.5rem;
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.3));
}

.case-title {
    font-family: 'Libre Baskerville', serif;
    font-weight: 700;
    font-size: clamp(1.1rem, 2.2vw, 1.4rem);
    color: #E8D5B7;
    letter-spacing: 0.02em;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.case-description {
    font-family: 'Lora', serif;
    font-size: clamp(0.85rem, 1.5vw, 1rem);
    color: #C4B8A8;
    line-height: 1.7;
}

/* --- Porthole Transitions --- */
.porthole-transition {
    height: 30vh;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    background: #0A1628;
}

.porthole-ring {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 4px solid #C8935A;
    box-shadow:
        inset 0 0 20px rgba(10, 22, 40, 0.8),
        0 0 15px rgba(200, 147, 90, 0.2),
        inset 0 1px 0 rgba(232, 213, 183, 0.3),
        inset 0 -1px 0 rgba(139, 107, 61, 0.5);
    position: relative;
    transition: transform 0.6s ease;
}

.porthole-ring::before {
    content: '';
    position: absolute;
    top: 4px;
    left: 4px;
    right: 4px;
    bottom: 4px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(18, 34, 64, 0.6), rgba(10, 22, 40, 0.9));
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.4);
}

.porthole-ring::after {
    content: '';
    position: absolute;
    top: 8px;
    left: 30%;
    width: 40%;
    height: 20%;
    background: radial-gradient(ellipse, rgba(255, 255, 255, 0.08), transparent);
    border-radius: 50%;
}

/* Porthole clip-path reveal on scroll */
.porthole-transition .porthole-ring {
    clip-path: circle(var(--porthole-radius, 10%) at 50% 50%);
}

/* --- Narrative Text --- */
.narrative-text {
    font-family: 'Lora', serif;
    font-style: italic;
    font-size: clamp(0.95rem, 1.8vw, 1.15rem);
    color: #C4B8A8;
    line-height: 1.85;
    text-align: center;
    max-width: 600px;
    margin: 2rem auto;
    opacity: 0;
    transform: translateY(15px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.narrative-text.revealed {
    opacity: 1;
    transform: translateY(0);
}

.archive-narrative {
    margin-top: 1rem;
}

/* --- Abyss Section --- */
.abyss-closing {
    position: relative;
    margin-top: 2rem;
}

.abyss-narrative {
    color: #7EC8C8;
}

.abyss-glow {
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 200px;
    background: radial-gradient(circle, rgba(74, 234, 204, 0.08), transparent 70%);
    pointer-events: none;
    animation: glowPulse 4s ease-in-out infinite;
}

@keyframes glowPulse {
    0%, 100% { opacity: 0.5; transform: translateX(-50%) scale(1); }
    50% { opacity: 0.8; transform: translateX(-50%) scale(1.1); }
}

/* --- Final Section --- */
.final-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 0.8rem;
}

.final-text {
    font-family: 'DM Sans', sans-serif;
    font-size: 0.8rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: #7EC8C8;
    opacity: 0;
    transition: opacity 1s ease;
}

.final-text.revealed {
    opacity: 1;
}

.final-subtext {
    font-family: 'Lora', serif;
    font-style: italic;
    font-size: 1rem;
    color: #C4B8A8;
    opacity: 0;
    transition: opacity 1s ease 0.3s;
}

.final-subtext.revealed {
    opacity: 1;
}

.final-lantern {
    margin-top: 1.5rem;
    filter: drop-shadow(0 0 15px rgba(200, 147, 90, 0.3));
    opacity: 0;
    transition: opacity 1s ease 0.6s;
}

.final-lantern.revealed {
    opacity: 1;
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .depth-gauge {
        right: 0.5rem;
    }

    .depth-gauge-frame {
        width: 30px;
        height: 150px;
    }

    .depth-gauge-needle {
        width: 14px;
        left: 4px;
    }

    .grotto-content {
        padding: 3rem 1.5rem;
    }

    .display-case {
        min-height: 280px;
        padding: 1.5rem;
    }

    .case-left,
    .case-left.revealed {
        transform: rotate(0deg) translateY(0);
    }

    .case-right,
    .case-right.revealed {
        transform: rotate(0deg) translateY(0);
    }

    .case-left:hover {
        transform: translateY(-4px);
    }

    .case-right:hover {
        transform: translateY(-4px);
    }

    .porthole-ring {
        width: 80px;
        height: 80px;
        border-width: 3px;
    }
}

@media (max-width: 480px) {
    .grotto-content {
        padding: 2rem 1rem;
    }

    .display-case {
        padding: 1.2rem;
        min-height: 260px;
    }
}