@font-face {
    font-family: 'RaiderCrusaderChrome';
    src: url('raidercrusaderchrome.ttf') format('truetype');
}

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

body {
    font-family: 'Cal Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: #000;
    min-height: 100vh;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.bouncing-letters {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: -1;
}

.bouncing-letter {
    position: absolute;
    font-family: 'RaiderCrusaderChrome', monospace;
    font-size: 80px;
    font-weight: bold;
    text-shadow: 0 0 20px currentColor;
    transition: color 0.1s ease;
    animation: bounce 8s linear infinite;
}

@keyframes bounce {
    0% { transform: translate(0, 0); }
    100% { transform: translate(calc(100vw - 80px), calc(100vh - 100px)); }
}

.newsroom-container {
    width: 100%;
    max-width: 1200px;
    aspect-ratio: 4/3;
    display: flex;
    flex-direction: column;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border: 4px solid #00d4ff;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 212, 255, 0.3);
    margin-top: 60px;
}

.news-header {
    background: rgba(0, 100, 200, 0.9);
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 10px rgba(0,0,0,0.3);
    position: relative;
    z-index: 10;
}

.news-logo {
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: 2px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.live-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    font-size: 0.9rem;
}

.live-dot {
    width: 12px;
    height: 12px;
    background: #ff4757;
    border-radius: 50%;
    animation: pulse 1.5s ease-in-out infinite;
}

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

.news-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    position: relative;
}

.news-anchor {
    flex: 1;
    display: flex;
    position: relative;
    background: url('News room.jpg') center/cover no-repeat;
    background-blend-mode: overlay;
    background-color: rgba(0, 60, 120, 0.3);
}

.anchor-info {
    position: absolute;
    bottom: 50px;
    left: 40px;
    z-index: 4;
    background: rgba(0, 100, 200, 0.9);
    padding: 20px 30px;
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(0, 212, 255, 0.3);
}

.anchor-name {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 5px;
    text-shadow: 0 4px 8px rgba(0,0,0,0.5);
    color: #00d4ff;
}

.anchor-title {
    font-size: 1.2rem;
    color: rgba(255,255,255,0.8);
    font-weight: 400;
}

.newsroom-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: auto;
    height: auto;
    background: none;
    display: flex;
    align-items: center;
    justify-content: center;
}

.character-image {
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
    z-index: 1;
}

.character-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    transition: all 0.5s ease;
}

.news-desk {
    position: absolute;
    bottom: -50px;
    left: 0;
    width: 100%;
    height: 250px;
    background: url('desk.png') center bottom/cover no-repeat;
    z-index: 3;
    pointer-events: none;
}

.story-image {
    position: absolute;
    top: -50px;
    right: -300px;
    width: 360px;
    height: 202px;
    border-radius: 15px;
    overflow: hidden;
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(0, 212, 255, 0.3);
    box-shadow: 0 15px 35px rgba(0,0,0,0.3);
    opacity: 0;
    transform: translateY(-20px) translateX(20px);
    transition: all 0.8s ease-out;
}

.story-image.fade-in {
    opacity: 1;
    transform: translateY(0) translateX(0);
}

.story-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.news-caption {
    background: rgba(0, 100, 200, 0.95);
    padding: 20px 30px;
    backdrop-filter: blur(20px);
    border-top: 3px solid #00d4ff;
    position: relative;
    display: flex;
    flex-direction: column;
}

.news-ticker-container {
    background: rgba(200, 20, 20, 0.9);
    width: 100%;
    overflow: hidden;
    white-space: nowrap;
    border-bottom: 2px solid rgba(255, 100, 100, 0.5);
    padding: 8px 0;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
}

.ticker-text {
    font-family: 'Space Mono', monospace;
    font-size: 1rem;
    font-weight: 700;
    color: white;
    text-shadow: 0 1px 2px rgba(0,0,0,0.5);
    will-change: transform;
    display: inline-block;
    animation: ticker-scroll 80s linear infinite;
}

@keyframes ticker-scroll {
    0% {
        transform: translateX(100vw);
    }
    100% {
        transform: translateX(-100%);
    }
}

.caption-text {
    font-family: 'Space Mono', monospace;
    font-size: 1.4rem;
    font-weight: 700;
    text-align: center;
    color: white;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
    letter-spacing: 1px;
    line-height: 1.4;
    animation: typewriter 0.5s ease-in-out;
    padding: 20px 30px;
}

@keyframes typewriter {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.news-controls {
    background: rgba(0,0,0,0.8);
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    backdrop-filter: blur(20px);
}

.next-btn {
    background: linear-gradient(135deg, #ff6b6b, #ee5a24);
    border: none;
    border-radius: 50px;
    padding: 15px 35px;
    font-size: 1.1rem;
    font-weight: 600;
    color: white;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    box-shadow: 0 8px 25px rgba(238, 90, 36, 0.3);
}

.next-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 30px rgba(238, 90, 36, 0.4);
}

.next-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-arrow {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1rem;
    transition: transform 0.3s ease;
}

.next-btn:hover .btn-arrow {
    transform: translateY(-50%) translateX(3px);
}

.audio-controls {
    display: flex;
    align-items: center;
    gap: 20px;
}

.toggle-container {
    display: flex;
    align-items: center;
    gap: 10px;
}

.toggle {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(255,255,255,0.2);
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

.toggle input:checked + .toggle-slider {
    background-color: #00d4ff;
}

.toggle input:checked + .toggle-slider:before {
    transform: translateX(26px);
}

.toggle-label {
    font-size: 0.9rem;
    color: rgba(255,255,255,0.8);
    font-weight: 500;
}

.mute-btn {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 50%;
    width: 45px;
    height: 45px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.mute-btn:hover {
    background: rgba(255,255,255,0.2);
    transform: scale(1.1);
}

.credits-btn {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 50%;
    width: 45px;
    height: 45px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.credits-btn:hover {
    background: rgba(255,255,255,0.2);
    transform: scale(1.1);
}

.gallery-btn {
    background: rgba(255,255,255,0.1);
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 50%;
    width: 45px;
    height: 45px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.gallery-btn:hover {
    background: rgba(255,255,255,0.2);
    transform: scale(1.1);
}

.credits-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.credits-modal.show {
    opacity: 1;
    visibility: visible;
}

.gallery-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.gallery-modal.show {
    opacity: 1;
    visibility: visible;
}

.gallery-content {
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border: 2px solid #00d4ff;
    border-radius: 15px;
    padding: 0;
    max-width: 80vw;
    max-height: 80vh;
    width: 900px;
    box-shadow: 0 20px 60px rgba(0, 212, 255, 0.3);
    transform: translateY(-20px);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
}

.gallery-modal.show .gallery-content {
    transform: translateY(0);
}

.gallery-header {
    background: rgba(0, 100, 200, 0.9);
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 13px 13px 0 0;
    flex-shrink: 0;
}

.gallery-header h3 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: white;
}

.close-gallery {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: background 0.3s ease;
}

.close-gallery:hover {
    background: rgba(255, 255, 255, 0.2);
}

.gallery-body {
    padding: 30px;
    overflow-y: auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 20px;
    max-height: 60vh;
}

.gallery-character {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 15px;
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 212, 255, 0.1);
}

.gallery-character:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 212, 255, 0.2);
}

.gallery-character img {
    width: 80px;
    height: 80px;
    object-fit: contain;
    border-radius: 8px;
    margin-bottom: 10px;
}

.gallery-character-name {
    font-size: 0.8rem;
    color: white;
    font-weight: 500;
    line-height: 1.2;
    word-break: break-word;
}

.credits-header {
    background: rgba(0, 100, 200, 0.9);
    padding: 20px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 13px 13px 0 0;
}

.credits-header h3 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: white;
}

.close-credits {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 5px;
    border-radius: 50%;
    transition: background 0.3s ease;
}

.close-credits:hover {
    background: rgba(255, 255, 255, 0.2);
}

.credits-body {
    padding: 30px;
    color: white;
    font-size: 1rem;
    line-height: 1.6;
}

.credits-body a {
    color: #00d4ff;
    text-decoration: none;
}

.credits-body a:hover {
    text-decoration: underline;
}

.interview-segment {
    flex: 1;
    display: none;
    flex-direction: column;
    position: relative;
    background: url('interview-backgrounds.png') center/cover no-repeat;
}

.interview-segment.active {
    display: flex;
}

.news-anchor.interview-mode {
    display: none;
}

.interview-info {
    position: absolute;
    top: 40px;
    left: 40px;
    z-index: 4;
    background: rgba(200, 50, 50, 0.9);
    padding: 20px 30px;
    border-radius: 15px;
    backdrop-filter: blur(10px);
    border: 2px solid rgba(255, 100, 100, 0.3);
}

.interview-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 5px;
    text-shadow: 0 4px 8px rgba(0,0,0,0.5);
    color: #ff6b6b;
}

.interview-location {
    font-size: 1rem;
    color: rgba(255,255,255,0.8);
    font-weight: 400;
}

.interview-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.interviewee-characters {
    display: flex;
    align-items: flex-end;
    justify-content: space-around;
    width: 80%;
    height: 70%;
    position: relative;
    bottom: 50px;
}

.interviewee-character {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    max-width: 250px;
    max-height: 350px;
    position: relative;
}

.interviewee-character img {
    max-height: 300px;
    object-fit: contain;
    transition: all 0.5s ease;
}

.interviewee-name {
    position: absolute;
    bottom: -40px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
}

.news-desk.hidden {
    display: none;
}

.attribution {
    display: none;
}

.loading {
    opacity: 0.7;
    animation: pulse-loading 1s ease-in-out infinite alternate;
}

@keyframes pulse-loading {
    from { opacity: 0.5; }
    to { opacity: 1; }
}

.generating {
    animation: generating 0.5s ease-in-out infinite alternate;
}

@keyframes generating {
    from { opacity: 0.7; }
    to { opacity: 1; }
}

@media (max-width: 768px) {
    .anchor-name {
        font-size: 1.5rem;
    }
    
    .anchor-info {
        bottom: 30px;
        left: 20px;
        padding: 15px 20px;
    }
    
    .character-image {
        width: 300px;
        height: 300px;
    }
    
    .caption-text {
        font-size: 1.1rem;
    }
    
    .news-controls {
        flex-direction: column;
        gap: 15px;
        padding: 15px;
    }
    
    .audio-controls {
        width: 100%;
        justify-content: center;
    }
}