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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    overflow: hidden;
}

#app {
    width: 100%;
    height: 100vh;
    position: relative;
}

.screen {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.screen.active {
    display: flex;
}

/* Welcome Screen */
#welcome-screen {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.logo-container {
    margin-bottom: 60px;
}

.logo {
    width: 150px;
    height: 150px;
    filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.2));
}

/* Buttons */
.primary-button, .secondary-button {
    padding: 16px 48px;
    font-size: 18px;
    font-weight: 600;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.primary-button {
    background: white;
    color: #667eea;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.primary-button:active {
    transform: scale(0.95);
}

.secondary-button {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    backdrop-filter: blur(10px);
    margin-top: 20px;
}

/* Scanner Screen */
#scanner-screen {
    background: black;
    padding: 0;
}

.scanner-container {
    width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

#video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.scanner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.5);
}

.scanner-frame {
    width: 250px;
    height: 250px;
    border: 3px solid #4A90E2;
    border-radius: 20px;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.5);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { border-color: #4A90E2; }
    50% { border-color: #667eea; }
}

.scanner-info {
    position: absolute;
    bottom: 120px;
    text-align: center;
    color: white;
    z-index: 10;
}

.scanner-info p {
    margin: 5px 0;
    font-size: 16px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.timer {
    font-size: 20px;
    font-weight: bold;
    color: #4A90E2;
}

#cancel-scan {
    position: absolute;
    bottom: 40px;
    z-index: 10;
}

/* Video Player Screen */
#video-screen {
    background: black;
    padding: 0;
}

.video-container {
    width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    flex-direction: column;
}

#youtube-player {
    flex: 1;
    width: 100%;
    height: 100%;
}

.close-button {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    border: none;
    padding: 15px 30px;
    border-radius: 30px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    z-index: 10;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
}

.close-button:active {
    transform: translateX(-50%) scale(0.95);
}

/* Error display on video screen */
.error-display {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    padding: 40px;
    text-align: center;
    background: linear-gradient(135deg, #eb3349 0%, #f45c43 100%);
}

.error-display .error-icon {
    font-size: 80px;
    margin-bottom: 20px;
}

.error-display h2 {
    color: white;
    font-size: 28px;
    margin-bottom: 15px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.error-display p {
    color: white;
    font-size: 16px;
    margin-bottom: 30px;
    opacity: 0.9;
}



/* Error Screen */
#error-screen {
    background: linear-gradient(135deg, #eb3349 0%, #f45c43 100%);
}

.error-container {
    text-align: center;
    color: white;
}

.error-icon {
    font-size: 80px;
    margin-bottom: 20px;
}

.error-container h2 {
    font-size: 28px;
    margin-bottom: 15px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.error-container p {
    font-size: 18px;
    margin-bottom: 40px;
    opacity: 0.9;
}

