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

body {
    font-family: 'Courier New', Courier, monospace;
    background: #A8D5BA;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2C2416;
    position: relative;
    overflow: hidden;
}

/* Wave pattern background - Enhanced visibility */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        linear-gradient(135deg, transparent 48%, rgba(255,255,255,0.3) 48%, rgba(255,255,255,0.3) 52%, transparent 52%),
        linear-gradient(45deg, transparent 48%, rgba(255,255,255,0.25) 48%, rgba(255,255,255,0.25) 52%, transparent 52%);
    background-size: 60px 60px;
    pointer-events: none;
    z-index: 1;
}

/* Wave overlay at bottom */
body::after {
    content: '';
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 250px;
    background:
        radial-gradient(ellipse at center bottom, rgba(123, 196, 168, 0.5) 0%, transparent 70%);
    pointer-events: none;
    z-index: 1;
}

/* Visible wave decorations at bottom */
.wave-decoration-bottom {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 180px;
    z-index: 1;
    pointer-events: none;
    background-image:
        url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 120" preserveAspectRatio="none"><path d="M0,60 Q300,90 600,60 T1200,60 L1200,120 L0,120 Z" fill="%23EDD9C3" opacity="0.6"/></svg>'),
        url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1200 120" preserveAspectRatio="none"><path d="M0,80 Q300,50 600,80 T1200,80 L1200,120 L0,120 Z" fill="%237BC4A8" opacity="0.5"/></svg>');
    background-size: 100% 100%, 100% 100%;
    background-position: bottom, bottom;
    background-repeat: no-repeat;
}

.screen {
    display: none;
    width: 100%;
    min-height: 100vh;
    padding: 20px;
    position: relative;
    z-index: 2;
}

.screen.active {
    display: flex;
    align-items: center;
    justify-content: center;
}

.container {
    background: #F5E6D3;
    border: 4px solid #2C2416;
    border-radius: 8px;
    padding: 0;
    max-width: 900px;
    width: 100%;
    max-height: 90vh;
    box-shadow:
        8px 8px 0px #3D3427,
        12px 12px 20px rgba(0, 0, 0, 0.2);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.container-header {
    background: #2C2416;
    padding: 12px 20px;
    border-bottom: 3px solid #2C2416;
    display: flex;
    align-items: center;
    gap: 15px;
}

.header-dots {
    display: flex;
    gap: 8px;
}

.header-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid #F5E6D3;
}

.header-dot.red {
    background: #E8A5A5;
}

.header-dot.yellow {
    background: #EDD9C3;
}

.header-dot.green {
    background: #7BC4A8;
}

.breadcrumb {
    flex: 1;
    font-family: 'Courier New', Courier, monospace;
    font-size: 13px;
    color: #F5E6D3;
    font-weight: normal;
    text-align: center;
    letter-spacing: 0.5px;
}

.breadcrumb-path {
    color: #A8D5BA;
}

.container-body {
    padding: 40px;
    overflow-y: auto;
    flex: 1;
    max-height: calc(90vh - 60px);
}

/* Custom scrollbar for retro theme */
.container-body::-webkit-scrollbar {
    width: 12px;
}

.container-body::-webkit-scrollbar-track {
    background: #EDD9C3;
    border-left: 2px solid #2C2416;
}

.container-body::-webkit-scrollbar-thumb {
    background: #7BC4A8;
    border: 2px solid #2C2416;
}

.container-body::-webkit-scrollbar-thumb:hover {
    background: #A8D5BA;
}

/* Retro corner decoration */
.container::before,
.container::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    border: 3px solid #2C2416;
}

.container::before {
    top: -3px;
    left: -3px;
    border-right: none;
    border-bottom: none;
}

.container::after {
    bottom: -3px;
    right: -3px;
    border-left: none;
    border-top: none;
}

h1, h2 {
    text-align: center;
    color: #2C2416;
    margin-bottom: 20px;
    font-family: 'Courier New', Courier, monospace;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 2px;
    text-shadow: 2px 2px 0px rgba(124, 196, 168, 0.3);
}

h1 {
    font-size: 28px;
}

h2 {
    font-size: 22px;
}

p {
    text-align: center;
    margin-bottom: 30px;
    color: #3D3427;
    font-family: 'Courier New', Courier, monospace;
}

/* Count Selection Screen */
.count-options {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.count-btn {
    padding: 30px 20px;
    font-size: 20px;
    font-weight: bold;
    font-family: 'Courier New', Courier, monospace;
    background: #EDD9C3;
    color: #2C2416;
    border: 3px solid #2C2416;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 4px 4px 0px #3D3427;
    position: relative;
}

.count-btn:hover {
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0px #3D3427;
    background: #7BC4A8;
}

.count-btn:active {
    transform: translate(4px, 4px);
    box-shadow: 0px 0px 0px #3D3427;
}

.count-btn small {
    display: block;
    margin-top: 8px;
    font-size: 12px;
    opacity: 0.7;
}

/* Camera Screen */
.camera-container {
    position: relative;
    width: 100%;
    max-width: 640px;
    margin: 0 auto 20px;
    background: #000;
    border: 4px solid #2C2416;
    border-radius: 4px;
    overflow: hidden;
    box-shadow: 6px 6px 0px #3D3427;
}

#video, #video-retro {
    width: 100%;
    height: auto;
    display: block;
}

#canvas {
    width: 100%;
    height: auto;
}

.countdown {
    text-align: center;
    font-size: 72px;
    font-weight: bold;
    font-family: 'Courier New', Courier, monospace;
    color: #2C2416;
    min-height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-shadow: 3px 3px 0px rgba(124, 196, 168, 0.5);
}

/* Buttons */
.btn-primary, .btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    max-width: 300px;
    margin: 10px auto;
    padding: 15px 30px;
    font-size: 16px;
    font-weight: bold;
    font-family: 'Courier New', Courier, monospace;
    text-transform: uppercase;
    letter-spacing: 1px;
    border: 3px solid #2C2416;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.15s;
}

.btn-primary {
    background: #7BC4A8;
    color: #2C2416;
    box-shadow: 5px 5px 0px #3D3427;
}

.btn-primary:hover {
    transform: translate(2px, 2px);
    box-shadow: 3px 3px 0px #3D3427;
    background: #A8D5BA;
}

.btn-primary:active {
    transform: translate(5px, 5px);
    box-shadow: 0px 0px 0px #3D3427;
}

.btn-secondary {
    background: #EDD9C3;
    color: #2C2416;
    box-shadow: 5px 5px 0px #3D3427;
}

.btn-secondary:hover {
    transform: translate(2px, 2px);
    box-shadow: 3px 3px 0px #3D3427;
    background: #E8A5A5;
}

.btn-secondary:active {
    transform: translate(5px, 5px);
    box-shadow: 0px 0px 0px #3D3427;
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
    box-shadow: 5px 5px 0px #3D3427;
}

/* Photo Grid */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
    padding: 10px;
}

.photo-item {
    position: relative;
    cursor: pointer;
    border-radius: 4px;
    overflow: hidden;
    border: 3px solid #2C2416;
    transition: all 0.2s;
    box-shadow: 4px 4px 0px #3D3427;
    background: white;
}

.photo-item:hover {
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0px #3D3427;
}

.photo-item img {
    width: 100%;
    height: auto;
    display: block;
}

.photo-item.selected {
    border-color: #7BC4A8;
    border-width: 4px;
    box-shadow: 0 0 0 4px #7BC4A8, 6px 6px 0px #3D3427;
}

.photo-item .check-mark {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 35px;
    height: 35px;
    background: #7BC4A8;
    border: 3px solid #2C2416;
    border-radius: 50%;
    display: none;
    align-items: center;
    justify-content: center;
    color: #2C2416;
    font-weight: bold;
    font-size: 20px;
    box-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.photo-item.selected .check-mark {
    display: flex;
}

/* Frame Grid */
.frame-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
    margin-bottom: 30px;
    padding: 10px;
}

.frame-item {
    border: 3px solid #2C2416;
    border-radius: 4px;
    padding: 15px;
    cursor: pointer;
    transition: all 0.2s;
    background: #EDD9C3;
    box-shadow: 4px 4px 0px #3D3427;
    position: relative;
}

.frame-item:hover {
    border-color: #7BC4A8;
    transform: translate(2px, 2px);
    box-shadow: 2px 2px 0px #3D3427;
    background: #A8D5BA;
}

.frame-item:active {
    transform: translate(4px, 4px);
    box-shadow: 0px 0px 0px #3D3427;
}

.frame-item img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 2px;
    border: 2px solid #2C2416;
    background: #FFFFFF;
}

.frame-item .frame-name {
    text-align: center;
    margin-top: 12px;
    font-weight: bold;
    font-family: 'Courier New', Courier, monospace;
    color: #2C2416;
    text-transform: uppercase;
    font-size: 13px;
    letter-spacing: 1px;
    padding: 8px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 2px;
}

/* Final Canvas */
#final-canvas {
    display: block;
    max-width: 100%;
    height: auto;
    margin: 20px auto 40px;
    border-radius: 4px;
    border: 4px solid #2C2416;
    box-shadow: 8px 8px 0px #3D3427;
}

.action-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 30px;
    padding: 20px 0;
}

.action-buttons button {
    margin: 0;
}

/* Additional retro decorations */
.container > h1::before,
.container > h1::after {
    content: '◆';
    margin: 0 15px;
    color: #7BC4A8;
}

/* Decorative corner elements */
.corner-decoration {
    position: fixed;
    z-index: 10;
    pointer-events: none;
}

.corner-decoration.top-left {
    top: 20px;
    left: 20px;
}

.corner-decoration.top-right {
    top: 20px;
    right: 20px;
}

.corner-decoration.bottom-left {
    bottom: 20px;
    left: 20px;
}

.corner-decoration.bottom-right {
    bottom: 20px;
    right: 20px;
}

/* Clock decoration - Enhanced version */
.clock-widget {
    background: #F5E6D3;
    border: 3px solid #2C2416;
    border-radius: 8px;
    padding: 16px;
    box-shadow: 4px 4px 0px #3D3427;
    font-family: 'Courier New', Courier, monospace;
    color: #2C2416;
    min-width: 240px;
    max-width: 280px;
}

.clock-icon {
    width: 50px;
    height: 50px;
    margin: 0 auto 12px;
    background: #2C2416;
    border: 2px solid #2C2416;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    font-weight: bold;
    color: #F5E6D3;
    font-family: 'Courier New', Courier, monospace;
}

.clock-icon::before {
    content: 'PC';
}

.clock-time {
    text-align: center;
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 16px;
    letter-spacing: 1px;
}

.system-stats {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
}

.stat-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.stat-label {
    font-size: 11px;
    font-weight: bold;
    width: 35px;
    text-transform: lowercase;
}

.stat-bar {
    flex: 1;
    height: 16px;
    background: white;
    border: 2px solid #2C2416;
    border-radius: 2px;
    overflow: hidden;
    position: relative;
}

.stat-fill {
    height: 100%;
    background: #7BC4A8;
    transition: width 1s ease;
}

.stat-fill.hour {
    background: #7BC4A8;
}

.stat-fill.min {
    background: #A8D5BA;
}

.stat-fill.sec {
    background: #E8A5A5;
}

.motivational-quote {
    text-align: center;
    font-size: 10px;
    margin-top: 12px;
    padding-top: 12px;
    border-top: 2px solid #2C2416;
    font-style: italic;
    line-height: 1.3;
    cursor: pointer;
    transition: all 0.3s ease;
    min-height: 30px;
    opacity: 1;
}

.motivational-quote:hover {
    color: #7BC4A8;
    transform: scale(1.05);
}

.motivational-quote:active {
    transform: scale(0.95);
}

/* Photo count widget */
.photo-count-widget {
    background: #EDD9C3;
    border: 3px solid #2C2416;
    border-radius: 4px;
    padding: 12px 16px;
    box-shadow: 4px 4px 0px #3D3427;
    font-family: 'Courier New', Courier, monospace;
    font-weight: bold;
    color: #2C2416;
    font-size: 12px;
    text-align: center;
}

.photo-count-widget::before {
    content: '[#]';
    display: block;
    font-size: 20px;
    margin-bottom: 4px;
    font-weight: bold;
}

/* Settings widget */
.settings-widget {
    background: #7BC4A8;
    border: 3px solid #2C2416;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    box-shadow: 4px 4px 0px #3D3427;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    font-weight: bold;
    font-family: 'Courier New', Courier, monospace;
    color: #2C2416;
}

.settings-widget::before {
    content: '[*]';
}

/* Info widget */
.info-widget {
    background: #A8D5BA;
    border: 3px solid #2C2416;
    border-radius: 4px;
    padding: 10px;
    box-shadow: 4px 4px 0px #3D3427;
    font-family: 'Courier New', Courier, monospace;
    font-size: 11px;
    color: #2C2416;
    max-width: 150px;
    line-height: 1.4;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .container {
        padding: 20px;
    }

    h1 {
        font-size: 22px;
    }

    h2 {
        font-size: 18px;
    }

    .count-options {
        grid-template-columns: 1fr;
    }

    .countdown {
        font-size: 48px;
    }

    .corner-decoration {
        display: none;
    }
}

/* --- Y2K THEME OVERRIDES --- */


body {
    font-family: 'Titan One', cursive !important;
    /* Main checkerboard background */
    background-image: conic-gradient(from 0deg, rgba(255,255,255,0.4) 90deg, transparent 90deg 180deg, rgba(255,255,255,0.4) 180deg 270deg, transparent 270deg);
    background-size: 100px 100px;
    background-color: #FFD1DC;
}

body .wave-decoration-bottom,
body .container::before,
body .container::after {
    display: none !important;
}

/* Base Container modifications */
body .container {
    border-radius: 20px;
    border-width: 4px;
    border-color: #111;
    box-shadow: 8px 8px 0px #111;
}

/* Background colors per screen */
body #screen-count-selection .container {
    background-color: #FFC0CB; /* Pink */
    background-image: conic-gradient(from 0deg, rgba(255,255,255,0.3) 90deg, transparent 90deg 180deg, rgba(255,255,255,0.3) 180deg 270deg, transparent 270deg);
    background-size: 60px 60px;
}
body #screen-camera .container,
body #screen-review .container,
body #screen-filters .container,
body #screen-frames .container {
    background-color: #FFEA70; /* Yellow */
    background-image: conic-gradient(from 0deg, rgba(255,255,255,0.4) 90deg, transparent 90deg 180deg, rgba(255,255,255,0.4) 180deg 270deg, transparent 270deg);
    background-size: 60px 60px;
}
body #screen-composition .container {
    background-color: #7BD3EA; /* Blue */
    background-image: conic-gradient(from 0deg, rgba(255,255,255,0.4) 90deg, transparent 90deg 180deg, rgba(255,255,255,0.4) 180deg 270deg, transparent 270deg);
    background-size: 40px 40px;
}

/* Header & Typography */
body .container-header {
    background: transparent;
    border-bottom: none;
}
body .header-dots {
    display: none;
}
body .breadcrumb {
    color: #111;
    font-size: 16px;
    font-weight: bold;
    font-family: 'Titan One', cursive;
}

body h1, body h2 {
    color: white;
    -webkit-text-stroke: 2px #111;
    text-shadow: 4px 4px 0px #111;
    letter-spacing: 2px;
    font-family: 'Titan One', cursive;
}
body p {
    font-family: 'Titan One', cursive;
    color: #111;
    background: white;
    padding: 8px 15px;
    border-radius: 12px;
    border: 3px solid #111;
    display: inline-block;
}

/* Buttons */
body .btn-primary {
    background: #8370F5;
    color: white;
    border-radius: 25px;
    border-color: #111;
    box-shadow: 5px 5px 0px #111;
    font-family: 'Titan One', cursive;
}
body .btn-secondary, body .count-btn {
    background: #FF9EAA;
    color: white;
    border-radius: 25px;
    border-color: #111;
    box-shadow: 5px 5px 0px #111;
    font-family: 'Titan One', cursive;
}

body .btn-primary:hover,
body .btn-secondary:hover,
body .count-btn:hover {
    box-shadow: 3px 3px 0px #111;
    opacity: 0.9;
}

/* Ornaments */
.y2k-ornament {
    position: fixed;
    pointer-events: none;
    z-index: 10;
    display: none;
}
body .y2k-ornament {
    display: block;
}

/* Transitions */
.photo-item, .frame-item {
    transition: all 0.2s ease-in-out;
}
body .photo-item.selected, body .frame-item.selected {
    outline: 4px solid #F63E2C;
    box-shadow: 0 0 15px rgba(246, 62, 44, 0.6), 6px 6px 0px #111;
}

/* Skewed Banner */
.y2k-skewed-banner {
    background: #E85A1C; /* Orange */
    color: white;
    font-family: 'Titan One', cursive;
    font-size: 32px;
    padding: 15px 30px;
    border: 3px solid #111;
    transform: rotate(-3deg);
    box-shadow: 6px 6px 0px #111;
    display: inline-block;
    line-height: 1.2;
    -webkit-text-stroke: 1px #111;
}



/* Theme Switcher Slider */
input:checked + .slider {
    background-color: #8370F5;
}
input:checked + .slider .slider-ball {
    transform: translateX(26px);
}

/* Hide corner decorations and theme switcher on Welcome Screen */
body:has(#screen-welcome.active) .corner-decoration,


/* Y2K Diagonal Pink & White Stripes Background */
body {
    background: url('Assets/BGY2K.png') no-repeat center center fixed !important;
    background-size: cover !important;
}

/* Mobile background for Y2K globally */
@media (max-width: 768px) {
    body {
        background: url('Assets/BGY2K_mobile.png') no-repeat center center fixed !important;
        background-size: cover !important;
    }
}

/* User fixes for Y2K layout */
body .breadcrumb {
    display: none !important;
}
body .y2k-ornament {
    display: none !important;
}

.y2k-skewed-banner {
    width: 95vw !important;
      max-width: 700px !important;
    font-size: clamp(32px, 8vw, 80px) !important;
    padding: 2vw 4vw !important;
    max-width: 95% !important;
    text-align: right !important;
    font-style: italic;
    -webkit-text-stroke: 0 !important;
    text-shadow: none !important;
    padding: 20px 30px !important;
}

/* Ensure Welcome screen has no weird container styles */
body #screen-welcome .container {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

body #screen-welcome p {
    background: transparent !important;
    text-shadow: none !important;
    font-weight: 900 !important;
    -webkit-text-stroke: 0 !important;
    font-size: 16px !important;
}

/* Hide global diagonal grid for Y2K theme */
body::before {
    display: none !important;
}

.y2k-skewed-banner {
    font-family: 'Titan One', cursive !important;
}

/* Force Titan One on Start Screen elements */
body #screen-welcome,
body #screen-welcome button,
body #screen-welcome .y2k-skewed-banner {
    font-family: 'Titan One', cursive !important;
}

/* =========================================
   Y2K CAMERA LAYOUT SPECIFIC STYLES
   ========================================= */



body #camera-layout-retro {
    display: none !important;
}

body #camera-layout-y2k {
    display: flex !important;
    background: transparent;
    border: none;
    box-shadow: none;
}

.y2k-timer-box {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-bottom: 20px;
    z-index: 10;
}

.y2k-arrow {
    font-size: 24px;
    color: #111;
}

.y2k-timer-inner {
    background: #fff;
    border: 3px solid #111;
    border-radius: 8px;
    box-shadow: 4px 4px 0px #111;
    text-align: center;
    min-width: 150px;
    position: relative;
    padding: 0;
}

.y2k-timer-text {
    background: #111;
    color: #FF5252;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    font-size: 24px;
    padding: 5px 15px;
    border-radius: 4px;
    margin: -10px 10px 5px 10px;
    border: 2px solid #fff;
    display: inline-block;
    position: relative;
    top: -10px;
}

.y2k-timer-label {
    font-family: 'Titan One', cursive;
    font-size: 16px;
    padding-bottom: 5px;
    color: #111;
}

.y2k-camera-wrapper {
    width: 90vw;
    max-width: 800px;
    border:   4px solid #111;
    background: #80DEEA;
    box-shadow: 8px 8px 0px rgba(0,0,0,0.1);
    position: relative;
    z-index: 10;
    margin-bottom: 20px;
    padding: 20px;
}

.y2k-camera-header {
    padding: 5px 20px;
    transform: rotate(3deg) translateY(-15px); /* Miring lebih tajam */
    background: #30D1A4;
    color: #fff;
    font-family: 'Titan One', cursive;
    font-size: 42px;
    text-align: center;
    
    border: 4px solid #111;
    -webkit-text-stroke: 1px #111;
    margin-left: -15px;
    margin-right: -15px;
    margin-top: -20px;
    border-radius: 8px;
    box-shadow: 4px 4px 0px #111;
    position: relative;
    z-index: 12;
}

.y2k-video-container {
    position: relative;
    background: transparent;
    padding:    0 ;
}

#video-y2k {
    width: 100%;
    display: block;
    outline: 4px solid #111;
    background: #000;
}

.y2k-sticker-slider {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    background: rgba(255,255,255,0.7);
    padding: 10px;
    border-radius: 20px;
    border: 2px solid #ccc;
}

.y2k-sticker-item {
    background: #FFF9C4;
    border: 3px solid #111;
    border-radius: 8px;
    padding: 5px;
    width: 40px;
    height: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 2px 2px 0px #111;
    cursor: pointer;
}

.y2k-countdown-huge {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 150px;
    font-family: 'Titan One', cursive;
    color: #111;
    text-shadow: 0 0 20px rgba(0,0,0,0.5);
    z-index: 20;
    pointer-events: none;
    opacity: 0.8;
}

.y2k-btn-capture {
    background: #8370F5;
    color: white;
    font-family: 'Titan One', cursive;
    font-size: 24px;
    padding: 15px 40px;
    border: 3px solid #111;
    border-radius: 25px;
    box-shadow: 4px 4px 0px #111;
    cursor: pointer;
    text-transform: uppercase;
    -webkit-text-stroke: 1px #111;
    z-index: 10;
}

.y2k-ornament-smiley {
    position: absolute;
    bottom: 20px;
    left: 20px;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 3px solid #111;
    background: #FFEB3B;
    box-shadow: 4px 4px 0px #111;
    object-fit: cover;
    z-index: 20;
}

.y2k-ornament-goodvibes {
    position: absolute;
    top: 20px;
    right: 20px;
    background: #00BFA5;
    color: #fff;
    font-family: 'Titan One', cursive;
    padding: 5px 15px;
    border-radius: 8px;
    border: 3px solid #fff;
    transform: rotate(-10deg);
    box-shadow: 2px 2px 5px rgba(0,0,0,0.2);
    z-index: 5;
}

.y2k-ornament-star1 {
    position: absolute;
    bottom: 100px;
    left: 40px;
    color: #FFCA28;
    font-size: 30px;
    text-shadow: 1px 1px 0 #fff;
}
.y2k-ornament-star2 {
    position: absolute;
    top: 150px;
    right: 30px;
    color: #FFCA28;
    font-size: 40px;
    text-shadow: 1px 1px 0 #fff;
}

/* Hide Retro corner decorations when on Y2K theme */
body .corner-decoration {
    display: none !important;
}

/* AR Filter Box UI */
.ar-filter-box {
    position: relative;
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(5px);
    padding: 10px;
    border-radius: 40px;
    display: flex;
    justify-content: center;
    gap: 10px;
    z-index: 100;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
    margin-bottom: 20px;
}

.ar-btn {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    border: 3px solid #111;
    background: #FFF59D;
    font-size: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 2px 2px 0px #111;
    transition: transform 0.1s;
}

.ar-btn:active {
    transform: translate(2px, 2px);
    box-shadow: 0px 0px 0px #111;
}

.ar-btn.active {
    background: #FFF;
    border-color: #30D1A4;
}

#camera-layout-retro .camera-container #countdown-retro {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 120px;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    color: #FFF;
    -webkit-text-stroke: 3px #111;
    text-shadow: 0 0 20px rgba(0,0,0,0.8);
    z-index: 999;
    pointer-events: none;
}

/* Background khusus untuk layar sesi foto Y2K */
body:has(#screen-camera.active) {
    background: url('Assets/BGY2K_2.png') no-repeat center center fixed !important;
    background-size: cover !important;
}



/* Sembunyikan dekorasi gelombang hijau di semua layar secara permanen */
.wave-decoration-bottom {
    display: none !important;
}

@media (max-width: 768px) {
    /* 2. Container sizing */
    .container {
        padding: 15px;
        width: 95%;
        margin: 10px auto;
    }
    
    body .container {
        padding: 15px !important;
    }
    
    /* 3. Camera specific layout adjustments */
    .camera-container {
        margin-bottom: 10px;
    }
    
    /* 4. AR filters box flex wrapping */
    .ar-filter-box {
        flex-wrap: wrap;
        justify-content: center;
        gap: 5px;
    }
    
    .ar-btn {
        padding: 8px;
        font-size: 20px;
    }
    
    /* 5. Typography */
    .countdown, #countdown-retro, #countdown-y2k {
        font-size: 80px !important;
    }
    
    .btn-primary, .btn-secondary {
        font-size: 16px;
        padding: 12px 20px;
        width: 100%;
        margin-top: 10px;
    }
}




/* Y2K Stickers Styles */
#y2k-decorations {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 50; /* Above background, below main content */
    overflow: hidden;
}

body #y2k-decorations {
    display: block;
}

.y2k-sticker {
    position: absolute;
    filter: drop-shadow(4px 4px 0px rgba(0,0,0,0.2));
    animation: float-sticker 6s ease-in-out infinite;
    max-width: 150px;
    height: auto;
}

/* Individual Sticker Positions & Rotations */
.sticker-1 { top: 5%; left: 5%; transform: rotate(-15deg); animation-delay: 0s; max-width: 120px; }
.sticker-2 { top: 10%; right: 8%; transform: rotate(20deg); animation-delay: 1s; }
.sticker-3 { top: 40%; left: -2%; transform: rotate(-5deg); animation-delay: 2s; max-width: 180px; }
.sticker-4 { bottom: 20%; right: 5%; transform: rotate(12deg); animation-delay: 0.5s; max-width: 160px; }
.sticker-5 { bottom: 5%; left: 10%; transform: rotate(-25deg); animation-delay: 1.5s; }
.sticker-6 { top: 45%; right: -5%; transform: rotate(30deg); animation-delay: 2.5s; max-width: 140px; }

@keyframes float-sticker {
    0% { margin-top: 0px; }
    50% { margin-top: -15px; }
    100% { margin-top: 0px; }
}

@media (max-width: 768px) {
    .y2k-sticker { max-width: 100px; }
    .sticker-3 { left: -10%; max-width: 120px; }
    .sticker-6 { right: -10%; max-width: 100px; }
}

/* === TAMBAHAN CSS MOBILE KHUSUS UNTUK PERBAIKAN LAYOUT === */
@media (max-width: 768px) {
    /* 1. Welcome Screen Tweaks */
    .y2k-skewed-banner {
        font-size: clamp(24px, 6vw, 40px) !important;
        padding: 10px !important;
    }
    #screen-welcome p {
        font-size: 16px !important;
        margin-top: 20px !important;
    }
    #btn-start-now {
        font-size: 20px !important;
        padding: 15px 30px !important;
        max-width: 250px !important;
    }

    /* 2. Container & Layout Tweaks */
    

    /* 3. Y2K Specific Elements */
    .y2k-timer-box {
        transform: scale(0.7) !important;
        margin-bottom: 0px !important;
        margin-top: -10px !important;
    }
    .y2k-camera-wrapper {
        padding: 10px !important;
        border-width: 2px !important;
        width: 100% !important;
        box-sizing: border-box !important;
        margin-bottom: 10px !important;
    }
    .y2k-camera-header {
        font-size: 20px !important;
        top: -15px !important;
        padding: 5px 15px !important;
    }

    /* 4. Camera Video "Petak Tengah" (Square) */
    .camera-container, .y2k-video-container {
        position: relative !important;
        width: 100% !important;
        margin: 0 auto !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        overflow: hidden !important;
        border-radius: 8px !important;
    }
    video#video-retro, video#video-y2k, 
    canvas#ar-overlay-retro, canvas#ar-overlay-y2k {
        aspect-ratio: 1 / 1 !important;
        object-fit: cover !important;
        width: 100% !important;
        max-width: 400px !important;
        height: auto !important;
    }
    
    /* 5. Buttons & AR Filters */
    .y2k-btn-capture, #btn-capture-retro {
        padding: 12px 20px !important;
        font-size: 16px !important;
        margin-bottom: 10px !important;
        max-width: 90% !important;
    }
    .ar-filter-box {
        padding: 10px !important;
        gap: 5px !important;
        border-radius: 15px !important;
    }
    .ar-btn {
        width: 45px !important;
        height: 45px !important;
        padding: 0 !important;
        font-size: 20px !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
    }
}



/* ==========================================================================
   ANGIE-STYLE 2-PLAYER COLLABORATION & MULTIPLAYER STYLES
   ========================================================================== */

/* --- Duo Room Top Bar --- */
.duo-room-header {
    position: fixed;
    top: 15px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(10px);
    border: 3px solid #2C2416;
    border-radius: 30px;
    padding: 8px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    z-index: 10000;
    box-shadow: 4px 4px 0px #2C2416;
    font-family: 'Fredoka', 'Comic Sans MS', sans-serif;
    font-size: 15px;
}

.duo-room-header .header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.room-pill {
    background: #FFEAA7;
    border: 2px solid #2C2416;
    padding: 4px 12px;
    border-radius: 15px;
    font-weight: bold;
    color: #2C2416;
    letter-spacing: 0.5px;
}

.partner-pill {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
    background: #E8F5E9;
    border: 2px solid #2C2416;
    padding: 4px 12px;
    border-radius: 15px;
}

.online-indicator {
    width: 10px;
    height: 10px;
    background: #00E676;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 8px #00E676;
    animation: pulseGlow 1.5s infinite;
}

.waiting-indicator {
    width: 10px;
    height: 10px;
    background: #FFA726;
    border-radius: 50%;
    display: inline-block;
    animation: pulseGlow 1.5s infinite;
}

@keyframes pulseGlow {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.4; transform: scale(0.85); }
}

.btn-leave-room {
    background: #FF7675;
    color: white;
    border: 2px solid #2C2416;
    border-radius: 15px;
    padding: 4px 12px;
    font-weight: bold;
    cursor: pointer;
    font-size: 13px;
    transition: transform 0.15s;
}

.btn-leave-room:hover {
    transform: scale(1.05);
    background: #D63031;
}

/* --- Multiplayer Real-Time Cursors --- */
.cursor-layer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none;
    z-index: 999999;
    overflow: hidden;
}

.remote-cursor {
    position: absolute;
    transform: translate(-3px, -3px);
    pointer-events: none;
    transition: opacity 0.2s ease;
    will-change: left, top;
}

.remote-cursor.hidden {
    opacity: 0;
}

.remote-cursor-pointer {
    position: relative;
    filter: drop-shadow(2px 3px 4px rgba(0, 0, 0, 0.35));
}

.remote-cursor-pointer .cursor-arrow {
    display: block;
}

.remote-cursor-badge {
    position: absolute;
    left: 20px;
    top: 18px;
    display: flex;
    align-items: center;
    gap: 5px;
    color: white;
    padding: 3px 10px 3px 7px;
    border-radius: 20px;
    border: 2px solid white;
    font-family: 'Fredoka', 'Comic Sans MS', sans-serif;
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
    user-select: none;
    letter-spacing: 0.3px;
}

.remote-cursor-badge .cursor-avatar {
    font-size: 14px;
}

/* Click Burst Ripple Animations */
.click-burst {
    position: absolute;
    transform: translate(-50%, -50%);
    pointer-events: none;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.click-burst .burst-ring {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    border: 3px solid #FF69B4;
    animation: burstRing 0.8s cubic-bezier(0.1, 0.8, 0.3, 1) forwards;
}

.click-burst-guest .burst-ring {
    border-color: #00D2D3;
}

.click-burst .burst-symbol {
    font-size: 20px;
    animation: burstSymbol 0.8s ease-out forwards;
}

@keyframes burstRing {
    0% { transform: scale(0.2); opacity: 1; }
    100% { transform: scale(1.6); opacity: 0; }
}

@keyframes burstSymbol {
    0% { transform: scale(0.5) translateY(0); opacity: 1; }
    50% { transform: scale(1.3) translateY(-15px); opacity: 1; }
    100% { transform: scale(1) translateY(-30px); opacity: 0; }
}

/* --- Live Reactions Bar & Emojis --- */
.live-reaction-bar {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: rgba(255, 255, 255, 0.95);
    border: 3px solid #2C2416;
    border-radius: 40px;
    padding: 8px 16px;
    display: flex;
    gap: 10px;
    z-index: 10000;
    box-shadow: 4px 4px 0px #2C2416;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.live-reaction-bar.visible {
    transform: translateX(-50%) translateY(0);
}

.reaction-btn {
    background: transparent;
    border: none;
    font-size: 24px;
    cursor: pointer;
    padding: 6px;
    border-radius: 50%;
    transition: transform 0.15s, background 0.15s;
}

.reaction-btn:hover {
    transform: scale(1.35) rotate(10deg);
    background: rgba(255, 105, 180, 0.2);
}

.reaction-btn:active {
    transform: scale(0.9);
}

.floating-reaction {
    position: fixed;
    font-size: 38px;
    pointer-events: none;
    z-index: 99999;
    user-select: none;
    animation: floatReaction 2.2s cubic-bezier(0.2, 0.7, 0.4, 1) forwards;
    filter: drop-shadow(2px 4px 6px rgba(0, 0, 0, 0.25));
}

@keyframes floatReaction {
    0% {
        opacity: 0;
        transform: translateY(20px) scale(0.4) rotate(0deg);
    }
    15% {
        opacity: 1;
        transform: translateY(-20px) scale(1.2) rotate(10deg);
    }
    50% {
        transform: translateY(-120px) translateX(var(--sway-offset, 20px)) scale(1.1) rotate(-8deg);
    }
    100% {
        opacity: 0;
        transform: translateY(-260px) translateX(calc(var(--sway-offset, 20px) * 1.5)) scale(0.8) rotate(15deg);
    }
}

/* --- Lobby & Mode Selection Styles --- */
.lobby-container {
    max-width: 850px;
    border-radius: 20px;
    background: #FFFDF9;
}

.lobby-body {
    padding: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    max-height: 85vh;
    overflow-y: auto;
}

.lobby-body h2 {
    font-family: 'Titan One', cursive;
    color: #2C2416;
    font-size: 32px;
    margin-bottom: 25px;
    text-shadow: 2px 2px 0px #FFEAA7;
    text-align: center;
}

.mode-cards-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    width: 100%;
    max-width: 680px;
    margin-bottom: 25px;
}

.mode-card {
    background: #F8F9FA;
    border: 3px solid #2C2416;
    border-radius: 18px;
    padding: 22px 18px;
    text-align: center;
    cursor: pointer;
    position: relative;
    box-shadow: 4px 4px 0px #2C2416;
    transition: all 0.2s ease;
}

.mode-card:hover {
    transform: translateY(-4px);
    box-shadow: 6px 6px 0px #2C2416;
}

.mode-card.active {
    background: #FFE8F2;
    border-color: #8370F5;
    box-shadow: 5px 5px 0px #8370F5;
}

.mode-card .mode-icon {
    font-size: 42px;
    margin-bottom: 8px;
}

.mode-card .mode-title {
    font-family: 'Titan One', cursive;
    font-size: 20px;
    color: #2C2416;
    margin-bottom: 6px;
}

.mode-card .mode-desc {
    font-family: 'Fredoka', sans-serif;
    font-size: 13px;
    color: #636E72;
    line-height: 1.3;
}

.mode-badge {
    position: absolute;
    top: -12px;
    right: 12px;
    background: #FF69B4;
    color: white;
    font-family: 'Titan One', cursive;
    font-size: 11px;
    padding: 3px 10px;
    border-radius: 12px;
    border: 2px solid #2C2416;
    box-shadow: 2px 2px 0px #2C2416;
    animation: bounceBadge 2s infinite ease-in-out;
}

@keyframes bounceBadge {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-4px); }
}

/* Duo Setup Panel */
.duo-setup-box {
    width: 100%;
    max-width: 680px;
    background: #FFFFFF;
    border: 3px solid #2C2416;
    border-radius: 18px;
    padding: 24px;
    box-shadow: 4px 4px 0px #2C2416;
}

.player-customization-section {
    background: #F0EFFF;
    border: 2px dashed #8370F5;
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 20px;
}

.input-row {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 14px;
    text-align: left;
    font-family: 'Fredoka', sans-serif;
}

.y2k-input {
    background: white;
    border: 2px solid #2C2416;
    border-radius: 12px;
    padding: 10px 16px;
    font-family: 'Fredoka', 'Comic Sans MS', sans-serif;
    font-size: 16px;
    color: #2C2416;
    box-shadow: 2px 2px 0px #2C2416;
    outline: none;
    width: 100%;
}

.y2k-input:focus {
    border-color: #8370F5;
    box-shadow: 3px 3px 0px #8370F5;
}

.avatar-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
    font-family: 'Fredoka', sans-serif;
}

.avatar-grid {
    display: flex;
    gap: 8px;
}

.avatar-option {
    background: white;
    border: 2px solid #2C2416;
    border-radius: 12px;
    font-size: 22px;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 2px 2px 0px #2C2416;
    transition: all 0.15s;
}

.avatar-option:hover {
    transform: scale(1.15);
}

.avatar-option.selected {
    background: #FF69B4;
    border-color: #2C2416;
    box-shadow: 3px 3px 0px #2C2416;
    transform: scale(1.1);
}

.lobby-tab-buttons {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.lobby-tab-btn {
    flex: 1;
    background: #DFE6E9;
    border: 2px solid #2C2416;
    border-radius: 12px;
    padding: 10px;
    font-family: 'Fredoka', sans-serif;
    font-weight: 700;
    font-size: 15px;
    color: #2C2416;
    cursor: pointer;
    box-shadow: 2px 2px 0px #2C2416;
    transition: all 0.15s;
}

.lobby-tab-btn.active {
    background: #8370F5;
    color: white;
    box-shadow: 3px 3px 0px #2C2416;
}

.create-room-box, .join-room-box {
    display: flex;
    flex-direction: column;
    gap: 14px;
    text-align: left;
    font-family: 'Fredoka', sans-serif;
}

.room-code-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.room-code-header-row label {
    font-weight: 700;
    color: #2C2416;
    margin: 0;
    font-size: 15px;
}

.room-code-timer-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #FFF3CD;
    border: 2px solid #2C2416;
    border-radius: 20px;
    padding: 3px 10px;
    font-size: 12px;
    font-weight: 700;
    color: #856404;
    box-shadow: 2px 2px 0px #2C2416;
    transition: all 0.3s ease;
}

.room-code-timer-badge.warning {
    background: #FFD2D2;
    color: #C0392B;
    border-color: #C0392B;
    animation: urgentPulse 1s infinite ease-in-out;
}

@keyframes urgentPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

.room-code-auto-hint {
    font-size: 12px;
    color: #636E72;
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 4px;
    font-weight: 500;
}

.room-code-display-row, .share-link-row {
    display: flex;
    gap: 10px;
    align-items: center;
}

.room-code-input {
    font-family: 'Courier New', monospace;
    font-size: 24px;
    font-weight: bold;
    letter-spacing: 4px;
    text-align: center;
    background: #FFEAA7;
    border: 3px solid #2C2416;
    border-radius: 12px;
    padding: 8px 16px;
    color: #2C2416;
    box-shadow: 3px 3px 0px #2C2416;
    flex: 1;
}

.btn-sm {
    padding: 10px 16px !important;
    font-size: 14px !important;
    white-space: nowrap;
}

.btn-large {
    width: 100%;
    padding: 14px 20px;
    font-size: 18px;
    font-family: 'Titan One', cursive;
    letter-spacing: 0.5px;
}

.btn-primary.disabled, .btn-primary:disabled {
    background: #B2BEC3 !important;
    border-color: #636E72 !important;
    box-shadow: none !important;
    cursor: not-allowed;
    transform: none !important;
}

.lobby-status-indicator {
    background: #FFF9E6;
    border: 2px solid #FFEAA7;
    border-radius: 12px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 600;
    color: #D35400;
}

.pulse-dot {
    width: 12px;
    height: 12px;
    background: #E67E22;
    border-radius: 50%;
    animation: pulseGlow 1.2s infinite;
}

.status-connected-box {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #2C2416;
}

.status-avatar {
    font-size: 28px;
}

/* --- DUO CAMERA SPLIT LAYOUT --- */
.duo-camera-layout {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 950px;
    margin: 0 auto;
    padding: 15px;
}

.duo-timer-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 12px;
    font-family: 'Titan One', cursive;
}

.duo-room-tag {
    background: #8370F5;
    color: white;
    padding: 6px 16px;
    border-radius: 20px;
    border: 2px solid #2C2416;
    box-shadow: 3px 3px 0px #2C2416;
    font-size: 14px;
}

.duo-timer-display {
    background: #2C2416;
    color: #55EFC4;
    font-family: 'Courier New', monospace;
    font-size: 24px;
    padding: 6px 20px;
    border-radius: 12px;
    border: 2px solid white;
    box-shadow: 3px 3px 0px rgba(0,0,0,0.3);
}

.duo-count-tag {
    background: #FF69B4;
    color: white;
    padding: 6px 16px;
    border-radius: 20px;
    border: 2px solid #2C2416;
    box-shadow: 3px 3px 0px #2C2416;
    font-size: 14px;
}

.duo-camera-split-container {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    width: 100%;
    background: #2C2416;
    padding: 16px;
    border-radius: 20px;
    box-shadow: 8px 8px 0px rgba(0, 0, 0, 0.25);
    border: 4px solid #FFEAA7;
}

.duo-video-slot {
    position: relative;
    background: #111;
    border-radius: 14px;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    display: flex;
    flex-direction: column;
    border: 3px solid #8370F5;
}

.duo-video-slot.remote-slot {
    border-color: #00D2D3;
}

.duo-player-label {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 10;
    color: white;
    font-family: 'Fredoka', 'Comic Sans MS', sans-serif;
    font-size: 13px;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 15px;
    border: 2px solid white;
    box-shadow: 2px 2px 0px rgba(0,0,0,0.4);
}

.host-label {
    background: linear-gradient(135deg, #FF69B4, #8370F5);
}

.guest-label {
    background: linear-gradient(135deg, #00D2D3, #54A0FF);
}

.video-crop-wrapper {
    width: 100%;
    height: 100%;
    position: relative;
    overflow: hidden;
}

.video-crop-wrapper video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scaleX(-1);
}

.duo-center-heart {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 32px;
    z-index: 20;
    background: white;
    width: 54px;
    height: 54px;
    border-radius: 50%;
    border: 3px solid #2C2416;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(255, 105, 180, 0.5);
    animation: pulseHeart 1.5s infinite ease-in-out;
}

@keyframes pulseHeart {
    0%, 100% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.18); }
}

.waiting-partner-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #2D3436;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: white;
    font-family: 'Fredoka', sans-serif;
    font-size: 14px;
    text-align: center;
    padding: 20px;
}

.has-partner-video .waiting-partner-placeholder {
    display: none;
}

.placeholder-icon {
    font-size: 48px;
    margin-bottom: 8px;
    animation: bounceBadge 2s infinite ease-in-out;
}

.duo-countdown-overlay {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.65);
    backdrop-filter: blur(4px);
    z-index: 30;
    border-radius: 20px;
    color: #FFEAA7;
    font-family: 'Titan One', cursive;
    font-size: 120px;
    align-items: center;
    justify-content: center;
    text-shadow: 4px 4px 0px #FF69B4, 8px 8px 0px #2C2416;
}

.duo-controls-row {
    margin-top: 18px;
    width: 100%;
    display: flex;
    justify-content: center;
}

.btn-capture-sparkle {
    background: linear-gradient(135deg, #FF69B4, #8370F5);
    color: white;
    font-family: 'Titan One', cursive;
    font-size: 24px;
    padding: 16px 40px;
    border-radius: 30px;
    border: 3px solid #2C2416;
    box-shadow: 6px 6px 0px #2C2416;
    cursor: pointer;
    transition: all 0.15s ease;
    letter-spacing: 0.5px;
}

.btn-capture-sparkle:hover {
    transform: translateY(-3px) scale(1.03);
    box-shadow: 8px 8px 0px #2C2416;
    filter: brightness(1.08);
}

.btn-capture-sparkle:active {
    transform: translateY(2px);
    box-shadow: 3px 3px 0px #2C2416;
}

/* Collaborative Selection Indicators */
.partner-selected-badge {
    position: absolute;
    bottom: 6px;
    left: 6px;
    background: #00D2D3;
    color: #2C2416;
    border: 2px solid #2C2416;
    border-radius: 12px;
    font-family: 'Fredoka', sans-serif;
    font-size: 11px;
    font-weight: 700;
    padding: 2px 8px;
    box-shadow: 2px 2px 0px #2C2416;
    z-index: 5;
}
.frame-item.selected-by-partner {
    border-color: #00D2D3 !important;
    box-shadow: 0 0 15px #00D2D3 !important;
}

/* Toast Popups */
.pb-toast {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background: #2C2416;
    color: #FFEAA7;
    font-family: 'Fredoka', 'Comic Sans MS', sans-serif;
    font-size: 15px;
    font-weight: 700;
    padding: 10px 24px;
    border-radius: 25px;
    border: 2px solid #FFEAA7;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    z-index: 1000000;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.pb-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* Responsive adjustments for mobile duo photobooth */
@media (max-width: 768px) {
    .mode-cards-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .duo-camera-split-container {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .duo-center-heart {
        display: none;
    }

    .btn-capture-sparkle {
        font-size: 18px;
        padding: 12px 25px;
    }
}

/* ==========================================================================
   AVATAR, SVG ICONS & TEXT ALIGNMENTS
   ========================================================================== */

/* Universal SVG Icon Alignment */
svg {
    vertical-align: middle;
}

/* Avatar Selection Grid & Vector Icon Buttons */
.avatar-row {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 10px;
}

.avatar-grid {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.avatar-option {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: #FFF9E6;
    border: 3px solid #2C2416;
    box-shadow: 3px 3px 0px #2C2416;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2C2416;
    transition: all 0.15s ease;
}

.avatar-option:hover {
    transform: translateY(-2px);
    background: #FFEAA7;
    box-shadow: 4px 4px 0px #2C2416;
}

.avatar-option.selected {
    background: #8370F5;
    color: white;
    transform: translateY(2px);
    box-shadow: 1px 1px 0px #2C2416;
    border-color: #2C2416;
}

.avatar-option svg {
    pointer-events: none;
    display: block;
}

.cursor-avatar {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-right: 2px;
}

/* Button, Pill, Tag & Badge Flex Alignment with SVGs */
.btn-primary, 
.btn-secondary, 
.btn-large, 
.btn-sm, 
.lobby-tab-btn, 
.btn-leave-room, 
.btn-capture-sparkle, 
.room-code-timer-badge,
.room-code-auto-hint,
.mode-badge,
.duo-room-tag,
.partner-pill,
.room-pill,
.lobby-status-indicator,
.y2k-btn-capture,
.action-buttons button,
.duo-count-tag,
.placeholder-icon,
.partner-selected-badge {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px;
    vertical-align: middle;
    line-height: 1;
}

.mode-badge {
    gap: 4px !important;
}

.room-code-auto-hint {
    gap: 6px !important;
    justify-content: flex-start !important;
}

.partner-pill, .room-pill {
    gap: 6px !important;
}

.room-code-timer-badge {
    gap: 6px !important;
}

.btn-primary svg, 
.btn-secondary svg, 
.btn-large svg, 
.btn-sm svg, 
.lobby-tab-btn svg, 
.btn-leave-room svg, 
.btn-capture-sparkle svg,
.room-code-timer-badge svg,
.room-code-auto-hint svg,
.mode-badge svg,
.duo-room-tag svg,
.partner-pill svg,
.room-pill svg,
.lobby-status-indicator svg,
.action-buttons button svg,
.y2k-btn-capture svg,
.partner-selected-badge svg {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    vertical-align: middle;
    flex-shrink: 0;
    pointer-events: none;
}

/* AR Filter Buttons with SVGs */
.ar-filter-box {
    display: flex;
    gap: 10px;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 10px;
}

.ar-btn {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    background: #FFF9E6;
    border: 2px solid #2C2416;
    box-shadow: 2px 2px 0px #2C2416;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #2C2416;
    transition: all 0.15s ease;
}

.ar-btn:hover {
    transform: translateY(-2px);
    background: #FFEAA7;
    box-shadow: 3px 3px 0px #2C2416;
}

.ar-btn.active, .ar-btn:active {
    background: #8370F5;
    color: white;
    transform: translateY(1px);
    box-shadow: 1px 1px 0px #2C2416;
}

.ar-btn svg {
    pointer-events: none;
    display: block;
}

/* Live Reactions Bar & Floating Animations */
.live-reaction-bar {
    position: fixed;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: rgba(255, 255, 255, 0.94);
    backdrop-filter: blur(8px);
    border: 3px solid #2C2416;
    border-radius: 30px;
    padding: 6px 14px;
    display: flex;
    gap: 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.25), 4px 4px 0px #2C2416;
    z-index: 99999;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.live-reaction-bar.visible {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
    pointer-events: auto;
}

.reaction-btn {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 2px solid transparent;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.15s ease, background 0.15s ease;
}

.reaction-btn:hover {
    transform: scale(1.25);
    background: #FFEAA7;
    border-color: #2C2416;
}

.floating-reaction {
    position: fixed;
    pointer-events: none;
    z-index: 100000;
    animation: floatReactionUp 2.2s forwards cubic-bezier(0.1, 0.8, 0.3, 1);
    display: flex;
    align-items: center;
    justify-content: center;
    filter: drop-shadow(0 4px 8px rgba(0,0,0,0.3));
}

.floating-reaction svg {
    width: 36px;
    height: 36px;
}

@keyframes floatReactionUp {
    0% {
        opacity: 0;
        transform: translateY(0) translateX(0) scale(0.4);
    }
    15% {
        opacity: 1;
        transform: translateY(-30px) translateX(calc(var(--sway-offset) * 0.3)) scale(1.2);
    }
    80% {
        opacity: 1;
        transform: translateY(-220px) translateX(var(--sway-offset)) scale(1);
    }
    100% {
        opacity: 0;
        transform: translateY(-300px) translateX(var(--sway-offset)) scale(0.8);
    }
}
