/* 
 * Style for Copilot Vendas TV Presentation 
 * Optimized for Smart TV displays (16:9, high readability, remote navigation)
 * Design Commitment: Technical / Geometric Minimalist (Sharp Edges, High Contrast Gold/Dark Gray)
 */

:root {
    --gold: #FFD700;
    --gold-dark: #cca000;
    --gold-glow: rgba(255, 215, 0, 0.15);
    
    --bg-body: #03060c;
    --bg-card: rgba(10, 15, 28, 0.9);
    --bg-panel: rgba(16, 24, 44, 0.8);
    --bg-accent: rgba(255, 215, 0, 0.05);
    
    --text-main: #f1f5f9;
    --text-dim: #94a3b8;
    --text-gold: #FFD700;
    --text-on-gold: #03060c;
    
    --border: rgba(255, 255, 255, 0.09);
    --border-gold: #FFD700;
    --border-active: rgba(255, 215, 0, 0.5);
    
    --font-tv: 'Outfit', sans-serif;
    --transition-slide: 0.4s cubic-bezier(0.16, 1, 0.3, 1); /* Ease out expo */
    
    --radius-sharp: 2px;
}

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

html, body {
    width: 100vw;
    height: 100vh;
    overflow: hidden;
    background-color: var(--bg-body);
    font-family: var(--font-tv);
    color: var(--text-main);
    -webkit-font-smoothing: antialiased;
}

/* TV Frame Container */
.tv-body {
    position: relative;
    user-select: none;
}

/* Geometric Overlay Grid */
.grid-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(255, 255, 255, 0.015) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.015) 1px, transparent 1px);
    background-size: 80px 80px;
    background-position: center;
    pointer-events: none;
    z-index: 1;
}

/* Scanline Effect for TV Display Feel */
.scanline-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        rgba(18, 16, 16, 0) 50%, 
        rgba(0, 0, 0, 0.25) 50%
    );
    background-size: 100% 4px;
    z-index: 10;
    pointer-events: none;
    opacity: 0.4;
}

/* Master Layout */
.tv-container {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 40px 60px;
    z-index: 2;
}

/* TV Header */
.tv-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid var(--border);
    padding-bottom: 20px;
    height: 60px;
}

.tv-header-left {
    display: flex;
    align-items: center;
    gap: 16px;
}

.tv-live-badge {
    background: rgba(255, 85, 0, 0.15);
    color: #ff5500;
    border: 1px solid rgba(255, 85, 0, 0.3);
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 2px;
    padding: 4px 12px;
    border-radius: var(--radius-sharp);
    display: flex;
    align-items: center;
    gap: 8px;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    background-color: #ff5500;
    border-radius: 50%;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% { transform: scale(0.9); opacity: 1; }
    50% { transform: scale(1.3); opacity: 0.4; }
    100% { transform: scale(0.9); opacity: 1; }
}

.tv-header-divider {
    color: rgba(255, 255, 255, 0.2);
    font-weight: 300;
    font-size: 1.2rem;
}

.tv-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 800;
    font-size: 1.2rem;
    letter-spacing: 2px;
    color: var(--text-main);
}

.tv-logo i {
    font-size: 1.3rem;
}

.tv-header-right {
    display: flex;
    align-items: center;
    gap: 24px;
}

.tv-module-tag {
    background: var(--bg-accent);
    color: var(--gold);
    border: 1px solid var(--border-gold);
    font-size: 0.85rem;
    font-weight: 800;
    letter-spacing: 1.5px;
    padding: 4px 16px;
    border-radius: var(--radius-sharp);
    text-transform: uppercase;
}

.tv-slide-counter {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-dim);
    font-variant-numeric: tabular-nums;
    letter-spacing: 1px;
}

/* TV Viewport for Slides */
.tv-viewport {
    flex-grow: 1;
    margin: 40px 0;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
}

.slide-transition-container {
    width: 100%;
    height: 100%;
    position: relative;
}

/* Slide Cards Styles */
.tv-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transform: translate3d(0, 20px, 0) scale(0.98);
    pointer-events: none;
    transition: opacity var(--transition-slide), transform var(--transition-slide);
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.tv-slide.active {
    opacity: 1;
    transform: translate3d(0, 0, 0) scale(1);
    pointer-events: auto;
    z-index: 5;
}

/* Dynamic Slide Layouts */

/* Layout 1: Hero (Capa) */
.tv-slide-hero {
    text-align: center;
    max-width: 1200px;
    margin: 0 auto;
}

.tv-slide-hero .hero-badge {
    font-size: 1.1rem;
    font-weight: 900;
    letter-spacing: 4px;
    color: var(--gold);
    text-transform: uppercase;
    margin-bottom: 24px;
    display: inline-block;
    border-bottom: 2px solid var(--gold);
    padding-bottom: 6px;
}

.tv-slide-hero h1 {
    font-size: 4.5rem;
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 30px;
    letter-spacing: -2px;
    background: linear-gradient(135deg, #ffffff 60%, var(--gold) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.tv-slide-hero p {
    font-size: 2.0rem;
    color: var(--text-dim);
    max-width: 900px;
    margin: 0 auto 40px;
    line-height: 1.4;
    font-weight: 400;
}

.tv-slide-hero ul {
    display: flex;
    justify-content: center;
    gap: 40px;
    list-style: none;
    margin-top: 20px;
}

.tv-slide-hero li {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    padding: 12px 24px;
    border-radius: var(--radius-sharp);
    display: flex;
    align-items: center;
    gap: 10px;
}

.tv-slide-hero li::before {
    content: "✦";
    color: var(--gold);
}

/* Layout 2: Split / Stacked for Standard Info */
.tv-slide-info {
    max-width: 1400px;
    width: 100%;
}

.tv-slide-info h2 {
    font-size: 3.5rem;
    font-weight: 900;
    letter-spacing: -1.5px;
    margin-bottom: 20px;
    color: var(--text-main);
    border-left: 6px solid var(--gold);
    padding-left: 20px;
    line-height: 1.1;
}

.tv-slide-info .slide-subtitle {
    font-size: 1.8rem;
    color: var(--text-dim);
    margin-bottom: 40px;
    line-height: 1.4;
}

.tv-slide-info ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 20px;
    max-width: 1100px;
}

.tv-slide-info li {
    font-size: 1.6rem;
    line-height: 1.5;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--border);
    padding: 24px 32px;
    border-radius: var(--radius-sharp);
    display: flex;
    align-items: flex-start;
    gap: 20px;
    transition: border-color 0.2s;
}

.tv-slide-info li strong {
    color: var(--gold);
    font-weight: 700;
}

.tv-slide-info li::before {
    content: "⚡";
    font-size: 1.6rem;
    color: var(--gold);
    line-height: 1;
}

/* Layout 3: Grid (Agenda & Objeções) - Break Standard Split Grid */
.tv-slide-grid {
    max-width: 1400px;
    width: 100%;
}

.tv-slide-grid h2 {
    font-size: 3.5rem;
    font-weight: 900;
    letter-spacing: -1.5px;
    margin-bottom: 20px;
    border-left: 6px solid var(--gold);
    padding-left: 20px;
}

.tv-slide-grid .slide-subtitle {
    font-size: 1.8rem;
    color: var(--text-dim);
    margin-bottom: 45px;
}

/* Dynamic grid columns with asymmetry */
.tv-grid-container {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 30px;
    align-items: stretch;
}

.tv-grid-container.three-cols {
    grid-template-columns: 1.1fr 1fr 0.9fr;
}

.tv-grid-container.four-cols {
    grid-template-columns: 1fr 1fr;
}

.tv-grid-card {
    background: rgba(255, 255, 255, 0.02);
    border: 2px solid var(--border);
    padding: 35px;
    border-radius: var(--radius-sharp);
    display: flex;
    flex-direction: column;
    gap: 20px;
    position: relative;
    overflow: hidden;
}

.tv-grid-card.highlighted {
    border-color: var(--border-gold);
    background: var(--bg-accent);
}

.tv-grid-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: var(--border);
}

.tv-grid-card.highlighted::before {
    background: var(--gold);
}

.tv-card-header {
    display: flex;
    align-items: center;
    gap: 16px;
}

.tv-card-number {
    font-size: 1.2rem;
    font-weight: 900;
    background: var(--gold);
    color: var(--text-on-gold);
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sharp);
}

.tv-grid-card h3 {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.2;
    color: var(--text-main);
}

.tv-grid-card p {
    font-size: 1.2rem;
    line-height: 1.5;
    color: var(--text-dim);
    margin-bottom: 0;
}

/* Layout 4: TV Interactive Prompt & QR Code (Outstanding UX) */
.tv-slide-prompt {
    max-width: 1400px;
    width: 100%;
}

.tv-slide-prompt h2 {
    font-size: 3.5rem;
    font-weight: 900;
    letter-spacing: -1.5px;
    margin-bottom: 15px;
    border-left: 6px solid var(--gold);
    padding-left: 20px;
}

.tv-slide-prompt .slide-subtitle {
    font-size: 1.6rem;
    color: var(--text-dim);
    margin-bottom: 35px;
}

.tv-prompt-layout {
    display: grid;
    grid-template-columns: 1.3fr 0.7fr;
    gap: 40px;
    align-items: stretch;
}

.tv-prompt-box-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.tv-prompt-box {
    background: rgba(255, 255, 255, 0.02);
    border: 2px solid var(--border-gold);
    border-left: 8px solid var(--gold);
    padding: 30px 40px;
    border-radius: var(--radius-sharp);
    position: relative;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

.tv-prompt-label {
    display: block;
    font-size: 0.9rem;
    font-weight: 900;
    color: var(--gold);
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 15px;
}

.tv-prompt-text {
    font-size: 1.5rem;
    line-height: 1.6;
    color: var(--text-main);
    font-weight: 500;
    font-style: italic;
}

.tv-prompt-steps {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tv-prompt-steps li {
    font-size: 1.3rem;
    color: var(--text-dim);
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.tv-prompt-steps li strong {
    color: var(--text-main);
}

.tv-prompt-steps li::before {
    content: "✓";
    color: var(--gold);
    font-weight: 900;
}

/* TV QR Code Block */
.tv-qr-card {
    background: rgba(255, 255, 255, 0.03);
    border: 2px dashed rgba(255, 215, 0, 0.3);
    border-radius: var(--radius-sharp);
    padding: 30px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 20px;
}

.tv-qr-wrapper {
    background: #ffffff;
    padding: 16px;
    border-radius: var(--radius-sharp);
    display: inline-flex;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.tv-qr-image {
    width: 160px;
    height: 160px;
    display: block;
}

.tv-qr-text {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-main);
}

.tv-qr-subtext {
    font-size: 0.9rem;
    color: var(--text-dim);
    line-height: 1.4;
}

/* Layout 5: Stats and Big Metrics */
.tv-slide-stats {
    max-width: 1400px;
    width: 100%;
}

.tv-slide-stats h2 {
    font-size: 3.5rem;
    font-weight: 900;
    letter-spacing: -1.5px;
    margin-bottom: 20px;
    border-left: 6px solid var(--gold);
    padding-left: 20px;
}

.tv-slide-stats .slide-subtitle {
    font-size: 1.8rem;
    color: var(--text-dim);
    margin-bottom: 50px;
}

.tv-stats-row {
    display: flex;
    gap: 40px;
    width: 100%;
}

.tv-stat-card {
    flex: 1;
    background: rgba(255, 255, 255, 0.02);
    border: 2px solid var(--border);
    padding: 40px;
    border-radius: var(--radius-sharp);
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 15px;
}

.tv-stat-value {
    font-size: 5rem;
    font-weight: 900;
    color: var(--gold);
    line-height: 1;
    letter-spacing: -2px;
}

.tv-stat-label {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--text-main);
    line-height: 1.4;
}

/* TV Footer and Progress Elements */
.tv-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 2px solid var(--border);
    padding-top: 20px;
    height: 60px;
}

.tv-footer-left {
    display: flex;
    align-items: center;
}

.tv-remote-keys {
    display: flex;
    align-items: center;
    gap: 10px;
}

.key-btn {
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text-main);
    width: 32px;
    height: 32px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    border-radius: var(--radius-sharp);
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.key-label {
    font-size: 1.0rem;
    font-weight: 700;
    color: var(--text-dim);
    margin-left: 10px;
}

/* Elegant Progress Track */
.tv-progress-track {
    flex-grow: 1;
    max-width: 600px;
    height: 6px;
    background: rgba(255, 255, 255, 0.05);
    margin: 0 40px;
    position: relative;
    border-radius: 3px;
    overflow: hidden;
}

.tv-progress-bar {
    height: 100%;
    background-color: var(--gold);
    box-shadow: 0 0 10px var(--gold-glow);
    transition: width var(--transition-slide);
}

.tv-footer-right {
    display: flex;
    align-items: center;
}

.tv-org-name {
    font-size: 1.0rem;
    font-weight: 700;
    color: var(--text-dim);
}

/* Toast Notifications for Remote Feedbacks */
.tv-toast {
    position: absolute;
    bottom: 120px;
    left: 50%;
    transform: translate3d(-50%, 50px, 0);
    opacity: 0;
    background: rgba(5, 10, 20, 0.95);
    border: 2px solid var(--border-gold);
    color: var(--text-main);
    padding: 16px 32px;
    border-radius: var(--radius-sharp);
    font-size: 1.2rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 16px;
    z-index: 100;
    transition: opacity 0.3s, transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    pointer-events: none;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.8);
}

.tv-toast.show {
    opacity: 1;
    transform: translate3d(-50%, 0, 0);
}
