/* Genel Sayfa Stilleri */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    margin: 0;
    padding: 0;
    color: #000000;
    background: radial-gradient(circle at center, #b3001f 0%, #6d0015 80%, #37000b 100%);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.container {
    width: 95%;
    max-width: 1400px;
    margin: 20px;
    padding: 20px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 10px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

h1, h2, h3 {
    text-align: center;
    color: #ffd1dc;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.7);
}

.viewer-count-banner {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
    font-weight: 600;
    color: #ffd1dc;
}

.viewer-count-banner strong {
    font-size: 1.3em;
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
    border-radius: 999px;
    padding: 6px 18px;
    min-width: 72px;
    text-align: center;
}

/* Panel Düzeni */
.panel-grid {
    display: grid;
    grid-template-columns: minmax(280px, 340px) 1fr;
    grid-template-areas: "side main";
    grid-gap: 24px;
    min-height: 70vh;
    align-items: stretch;
}

.main-content {
    grid-area: main;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    padding: 15px;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 16px;
    overflow: hidden;
    min-height: 480px;
}

/* Ana video container - çoklu video için grid */
#main-video-container {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #0d0d0d;
    background-image:
        linear-gradient(rgba(8, 8, 8, 0.82), rgba(8, 8, 8, 0.82)),
        url('../ankahed_logo.jpg');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    flex: 1 1 auto;
    min-height: 420px;
    border-radius: 12px;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.45);
}

/* Yayıncı video kartları */
.broadcaster-video {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 8px;
    border-radius: 12px;
}

.broadcaster-video-surface {
    width: 100%;
    background: #000;
    border-radius: 12px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.45);
    min-height: 220px;
    aspect-ratio: 16 / 9;
}

/* Mobil için video yüksekliği optimizasyonu */
@media (max-width: 768px) {
    .broadcaster-video-surface {
        min-height: 180px;
        aspect-ratio: 16 / 9;
    }
    
    /* Çoklu video durumunda alt alta dizilim için */
    #main-video-container.multi-video-mobile {
        display: grid !important;
        grid-template-columns: 1fr !important;
        gap: 10px !important;
    }
}

.broadcaster-video-label {
    padding: 6px 10px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.65);
    color: #f5f5f5;
    font-weight: 600;
    font-size: 0.95rem;
    text-align: center;
    align-self: center;
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.side-panel {
    grid-area: side;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.video-container, .controls, .q-and-a, .info-box {
    background: rgba(0, 0, 0, 0.3);
    border-radius: 8px;
    padding: 15px;
    display: flex;
    flex-direction: column;
}

/* Video ve Sunum Alanları */
.presenter-videos {
    display: flex;
    flex-direction: column;
    gap: 10px;
    height: 100%;
}

#remote-videos-container {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.presenter-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 12px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
}

.presenter-card-name {
    font-weight: 600;
    color: #fff;
}

.presenter-card-email {
    font-size: 0.8em;
    color: #ffd1dc;
    opacity: 0.8;
}

.presenter-card-status {
    font-size: 0.85em;
    color: #ffb3c1;
}

.presenter-card-status.is-live {
    color: #4caf50;
    font-weight: 600;
}

.reji-toggle {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.12);
    cursor: pointer;
    transition: background 0.2s ease, border 0.2s ease;
    position: relative;
}

.reji-toggle.is-on {
    background: rgba(76, 175, 80, 0.15);
    border-color: rgba(76, 175, 80, 0.6);
}

.reji-toggle input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.reji-toggle-track {
    width: 44px;
    height: 24px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.2);
    display: inline-flex;
    align-items: center;
    padding: 3px;
    transition: background 0.2s ease;
}

.reji-toggle.is-on .reji-toggle-track {
    background: #4caf50;
}

.reji-toggle-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #fff;
    transform: translateX(0);
    transition: transform 0.2s ease;
}

.reji-toggle.is-on .reji-toggle-thumb {
    transform: translateX(20px);
}

.reji-toggle-meta {
    display: flex;
    flex-direction: column;
    gap: 2px;
    font-size: 0.85em;
}

.reji-toggle-label {
    font-weight: 600;
    color: #fff;
}

.reji-toggle-status {
    color: #ffd1dc;
    font-size: 0.75em;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.info-box .reji-toggle {
    background: rgba(102, 126, 234, 0.1);
    border-color: rgba(118, 75, 162, 0.25);
    color: #1f2a44;
}

.info-box .reji-toggle .reji-toggle-label {
    color: #1f2a44;
}

.info-box .reji-toggle .reji-toggle-status {
    color: #455a64;
}

.info-box .reji-toggle-track {
    background: rgba(79, 99, 142, 0.2);
}

.info-box .reji-toggle.is-on {
    background: rgba(76, 175, 80, 0.18);
    border-color: rgba(76, 175, 80, 0.55);
}

.info-box .reji-toggle.is-on .reji-toggle-track {
    background: #2e7d32;
}

.info-box .reji-toggle-thumb {
    background: #ffffff;
}

.video-placeholder {
    background-color: #000;
    border: 1px solid #444;
    border-radius: 5px;
    flex-grow: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9em;
    color: #888;
}

#presentation-view {
    width: 100%;
    height: 100%;
    background: #1a1a1a;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ccc;
    font-size: 1.5em;
}

/* Form Elemanları */
.login-form, .info-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
}

.session-selection {
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: stretch;
}

.session-selection-hint {
    text-align: center;
    color: #ffd1dc;
    opacity: 0.9;
    margin: 0;
}

.session-selection-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    justify-content: center;
}

.session-selection-actions button {
    flex: 1 1 180px;
}

.session-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 12px;
}

.session-card {
    border: 1px solid rgba(255, 255, 255, 0.12);
    background: rgba(255, 255, 255, 0.05);
    border-radius: 10px;
    padding: 16px;
    text-align: left;
    cursor: pointer;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.session-card:hover {
    transform: translateY(-2px);
    border-color: rgba(255, 255, 255, 0.35);
}

.session-card.is-selected {
    border-color: #ff4d6d;
    background: rgba(255, 77, 109, 0.12);
}

.session-card__title {
    font-size: 1.1em;
    font-weight: 600;
    color: #fff;
    margin-bottom: 6px;
}

.session-card__meta {
    font-size: 0.85em;
    color: #ffd1dc;
    opacity: 0.9;
}

.session-list-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 24px;
    border-radius: 10px;
    background: rgba(0, 0, 0, 0.25);
    color: #ffd1dc;
}

.selected-session-info {
    text-align: center;
    color: #b3e5fc;
    font-weight: 600;
}

input[type="text"],
input[type="email"],
input[type="password"] {
    padding: 12px;
    border: 1px solid #8B0000;
    background-color: #37000b;
    color: #fff;
    border-radius: 5px;
    font-size: 1em;
}

input::placeholder {
    color: #aaa;
}

button {
    padding: 12px 20px;
    background-color: #b3001f;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 1.1em;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #ff4d6d;
}

.viewer-action-button {
    padding: 15px 30px;
    font-size: 1.1em;
    font-weight: bold;
    border-radius: 8px;
    border: none;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
}

.viewer-action-button:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(0, 0, 0, 0.4);
}

.viewer-action-button:active:not(:disabled) {
    transform: translateY(0);
}

.viewer-action-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

#viewer-buttons-container {
    min-height: 50px;
}

.input-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.input-group input {
    flex-grow: 1;
}

.input-group small {
    color: #ffcdd2;
    font-size: 0.8em;
}

/* Şifre Sayfası */
.password-hint {
    text-align: center;
    color: #ffd1dc;
    margin-bottom: 20px;
    line-height: 1.6;
}

#password-container .info-form {
    max-width: 450px;
}

#password-container h1 {
    margin-bottom: 10px;
}

/* Doktor Beyanı Checkbox */
.declaration-checkbox {
    margin: 10px 0;
    padding: 15px;
    background: rgba(139, 0, 0, 0.3);
    border: 1px solid rgba(255, 77, 109, 0.4);
    border-radius: 8px;
}

.declaration-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    cursor: pointer;
    user-select: none;
}

.declaration-label input[type="checkbox"] {
    width: 20px;
    height: 20px;
    min-width: 20px;
    margin-top: 2px;
    cursor: pointer;
    accent-color: #ff4d6d;
}

.declaration-text {
    font-size: 0.9em;
    line-height: 1.5;
    color: #ffd1dc;
}

.declaration-checkbox:has(input:checked) {
    border-color: rgba(76, 175, 80, 0.6);
    background: rgba(76, 175, 80, 0.15);
}

.declaration-checkbox:has(input:not(:checked)) .declaration-text {
    color: #ffcdd2;
}

.declaration-checkbox:has(input:checked) .declaration-text {
    color: #c8e6c9;
}

/* Soru-Cevap */
textarea {
    padding: 10px;
    min-height: 80px;
    border: 1px solid #8B0000;
    background-color: #37000b;
    color: #fff;
    border-radius: 5px;
    resize: vertical;
}

.hidden-dashboard {
    max-width: 1100px;
}

.hidden-dashboard__hint {
    text-align: center;
    color: #ffd1dc;
    opacity: 0.8;
    margin-top: -8px;
    margin-bottom: 24px;
}

.hidden-session-picker {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 24px;
}

.hidden-session-picker select {
    min-width: 260px;
    padding: 10px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    background: rgba(0, 0, 0, 0.35);
    color: #fff;
}

.hidden-stats-card {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.hidden-stat {
    padding: 18px;
    border-radius: 12px;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: inset 0 0 20px rgba(0, 0, 0, 0.25);
}

.hidden-stat--real {
    border-color: rgba(79, 195, 247, 0.6);
}

.hidden-stat--display {
    border-color: rgba(255, 77, 109, 0.5);
}

.hidden-stat--target {
    border-color: rgba(76, 175, 80, 0.6);
    background: rgba(76, 175, 80, 0.1);
}

.hidden-stat__label {
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 0.85em;
    color: #ffd1dc;
    margin-bottom: 8px;
}

.hidden-stat__value {
    font-size: 2.8em;
    font-weight: 700;
    margin: 0;
}

.hidden-controls {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}

.hidden-control-card {
    background: rgba(0, 0, 0, 0.35);
    border-radius: 12px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.hidden-control-card__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.hidden-control-card__badge {
    background: rgba(255, 255, 255, 0.12);
    padding: 6px 14px;
    border-radius: 999px;
    font-weight: 600;
}

.hidden-quick-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.hidden-quick-buttons button {
    flex: 1 1 80px;
    min-width: 80px;
    padding: 8px 0;
    font-size: 0.95em;
}

.hidden-control-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.hidden-control-actions button {
    flex: 1 1 140px;
}

.hidden-control-help {
    font-size: 0.85em;
    color: rgba(255, 255, 255, 0.75);
    margin: 0;
}

.hidden-control-status {
    font-size: 0.9em;
    color: #b3e5fc;
    margin: 0;
}

.hidden-inline-label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-weight: 600;
}

.hidden-inline-label input {
    padding: 10px;
    border-radius: 6px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    background: rgba(0, 0, 0, 0.35);
    color: #fff;
}

.ghost {
    background: rgba(255, 255, 255, 0.1);
}

.ghost:hover {
    background: rgba(255, 255, 255, 0.2);
}

.danger {
    background: #c0392b;
    border-color: #e74c3c;
}

.danger:hover {
    background: #e74c3c;
}

@media (max-width: 960px) {
    body {
        min-height: auto;
        padding: 10px 0 40px;
    }

    .container {
        width: 94%;
        margin: 12px auto;
        padding: 16px;
    }

    .panel-grid {
        grid-template-columns: 1fr;
        grid-template-areas:
            "main"
            "side";
        min-height: auto;
    }

    .side-panel,
    .main-content {
        grid-column: 1 / -1;
    }

    .main-content--top {
        order: -1;
    }

    #main-video-container {
        height: 320px;
        min-height: 320px;
    }

    .session-list {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }

    .session-card {
        padding: 14px;
    }

    .login-form,
    .info-form {
        max-width: 100%;
    }

    .input-group {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .input-group small {
        text-align: left;
    }

    #remote-videos-container {
        max-height: 280px;
        overflow-y: auto;
    }

    button {
        font-size: 1em;
        width: 100%;
    }

    .viewer-count-banner {
        justify-content: center;
    }

    .hidden-session-picker {
        flex-direction: column;
        align-items: stretch;
    }

    .hidden-controls {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 600px) {
    body {
        font-size: 15px;
    }

    .container {
        padding: 14px;
    }

    h1 {
        font-size: 1.6em;
    }

    .session-selection h3,
    .main-content h3,
    .side-panel h3 {
        font-size: 1.1em;
    }

    .panel-grid {
        gap: 12px;
    }

    #main-video-container {
        height: 360px;
        min-height: 360px;
    }

    textarea {
        min-height: 120px;
    }

    .session-list {
        grid-template-columns: 1fr;
    }

    .session-selection-actions {
        flex-direction: column;
    }

    .session-selection-actions button {
        flex: 1 1 auto;
    }

    #webinar-container .panel-grid {
        width: 100%;
    }

    #remote-videos-container {
        max-height: 220px;
    }

    .hidden-quick-buttons button {
        flex: 1 1 calc(50% - 8px);
    }
}

/* Yayın Kalitesi Anketi Modal */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    animation: modalFadeIn 0.3s ease-out;
}

.modal-content {
    background: linear-gradient(135deg, #2c1810 0%, #1a0f0a 100%);
    border-radius: 20px;
    padding: 0;
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    border: 2px solid rgba(255, 77, 109, 0.3);
    animation: modalSlideIn 0.4s ease-out;
}

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

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    padding: 25px 30px 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.modal-header h2 {
    margin: 0;
    color: #ffd1dc;
    font-size: 1.5em;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
}

.survey-timer {
    background: rgba(255, 77, 109, 0.2);
    border: 1px solid rgba(255, 77, 109, 0.4);
    border-radius: 25px;
    padding: 8px 16px;
    font-weight: 600;
    color: #ff6b8a;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.modal-body {
    padding: 30px;
}

.survey-description {
    text-align: center;
    color: #ffd1dc;
    font-size: 1.1em;
    margin-bottom: 25px;
    line-height: 1.5;
}

.rating-stars {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 25px;
    flex-wrap: wrap;
}

.rating-btn {
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    color: #fff;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 70px;
    text-align: center;
}

.rating-btn:hover {
    background: rgba(255, 77, 109, 0.3);
    border-color: rgba(255, 77, 109, 0.6);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(255, 77, 109, 0.3);
}

.rating-btn:active {
    transform: translateY(0);
}

.survey-warning {
    text-align: center;
    color: #ff6b8a;
    font-weight: 600;
    font-size: 0.95em;
    margin: 0;
    padding: 15px;
    background: rgba(255, 77, 109, 0.1);
    border-radius: 10px;
    border: 1px solid rgba(255, 77, 109, 0.3);
}

@media (max-width: 600px) {
    .modal-content {
        width: 95%;
        margin: 20px;
    }
    
    .modal-header {
        padding: 20px;
        flex-direction: column;
        text-align: center;
    }
    
    .modal-header h2 {
        font-size: 1.3em;
    }
    
    .modal-body {
        padding: 20px;
    }
    
    .rating-stars {
        gap: 6px;
    }
    
    .rating-btn {
        padding: 10px 12px;
        font-size: 0.9em;
        min-width: 60px;
    }
}