/* Impromptu Challenge CSS */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&display=swap');

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

body {
    font-family: 'Inter', Arial, sans-serif;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    color: #333;
    margin: 0;
    padding: 0;
    overflow: hidden;
    min-height: 100vh;
}

.hidden {
    display: none !important;
}

/* Login Page Styles */
.login-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 100vh;
    padding: 20px;
}

.login-logo {
    display: flex;
    justify-content: center;
    margin-bottom: 2rem;
}

.login-logo img, .logo {
    max-width: 300px;
    margin-bottom: 20px;
}

.login-form {
    width: 100%;
    max-width: 420px;
    margin: 0 auto;
    padding: 2.5rem;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.form-input-container {
    display: flex;
    flex-direction: column;
    width: 100%;
    gap: 20px;
}

.form-select, .form-input {
    height: 52px;
    padding: 0 15px;
    border-radius: 12px;
    border: 2px solid #dee2e6;
    font-size: 16px;
    background-color: #ffffff;
    transition: all 0.3s ease;
}

.form-select:focus, .form-input:focus {
    background-color: #ffffff;
    border-color: #6c757d;
    box-shadow: 0 0 0 3px rgba(108, 117, 125, 0.1);
    outline: none;
}

.form-select {
    margin: 0;
}

.form-input {
    margin: 0;
}

.submit-button, .cookie-button {
    font-size: 1.1rem;
    padding: 14px 30px;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    width: 100%;
}

.submit-button {
    margin-bottom: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 10px 25px rgba(102, 126, 234, 0.3);
}

.submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 35px rgba(102, 126, 234, 0.4);
}

.cookie-button {
    background: linear-gradient(135deg, #6c757d 0%, #495057 100%);
    color: white;
    box-shadow: 0 8px 20px rgba(108, 117, 125, 0.3);
}

.cookie-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 25px rgba(108, 117, 125, 0.4);
}

/* Main Challenge Page Styles */
.container {
    display: flex;
    flex-direction: column;
    height: 100vh;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
    padding: 10px;
    box-sizing: border-box;
    overflow: hidden;
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    margin-bottom: 10px;
}

.logo img {
    height: 50px;
}

.title {
    font-size: 24px;
    font-weight: bold;
    color: #333;
}

.flex-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    flex: 1;
    overflow: visible; /* hidden yerine visible yapın */
    height: auto; /* auto height ekleyin */
}

.left-panel {
    flex: 0 0 525px;
    min-width: unset;
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    overflow-y: auto;
}

.right-panel {
    flex: 1;
    min-width: unset;
    display: flex;
    flex-direction: column;
    background-color: white;
    border-radius: 10px;
    padding: 20px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
    overflow: hidden;
}

.room-header {
    background-color: #f97316;
    color: white;
    padding: 15px;
    font-size: 18px;
    font-weight: bold;
    text-align: center;
    border-radius: 8px;
    margin-bottom: 15px;
}

.judge-info {
    background-color: #06b6d4;
    color: white;
    padding: 12px;
    font-size: 16px;
    font-weight: bold;
    text-align: center;
    border-radius: 8px;
    margin-bottom: 15px;
}

.assessment-link {
    background-color: #9333ea;
    color: white;
    padding: 12px;
    font-size: 16px;
    font-weight: bold;
    text-align: center;
    border-radius: 8px;
    margin-bottom: 15px;
    position: relative;
}

.assessment-link a {
    color: white;
    text-decoration: none;
    display: block;
    width: 100%;
    height: 100%;
}

.assessment-link:hover {
    background-color: #7e22ce;
}

.section {
    background-color: #f3f4f6;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
}

.section-title {
    color: #4b5563;
    font-weight: 600;
    margin-bottom: 15px;
}

/* Selected Student Styles */
.participant-box {
    background-color: #22c55e;
    color: white;
    text-align: center;
    border-radius: 6px;
    padding: 12px;
    min-height: 30px;
    margin-bottom: 25px;
    border-left: 4px solid #166534;
    font-size: 30px;
    font-weight: 500;
    line-height: 1.3;
    display: flex;
    align-items: center;
    justify-content: center; /* Changed from space-between to center */
}

.student-status-gif {
    height: 30px;
    margin-left: 10px;
}

/* Topic Box Styles */
.topic-box {
    background-color: #ef4444;
    color: white;
    text-align: center;
    border-radius: 6px;
    padding: 12px;
    min-height: 30px;
    margin-bottom: 15px;
    border-left: 4px solid #991b1b;
    font-size: 28px;
    font-weight: 500;
    line-height: 1.3;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Timer Styles */
.timer {
    font-size: 48px;
    font-weight: bold;
    font-family: monospace;
    text-align: center;
    margin: 10px 0;
}

#prepTimer {
    color: #0ea5e9;
}

#talkTimer {
    color: #f97316;
}

.time-up {
    color: #dc2626;
    font-size: 24px;
    font-weight: bold;
    text-align: center;
    margin: 10px 0;
}

.timer-buttons {
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

.timer-button {
    padding: 12px;
    color: white;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    flex: 1;
    text-align: center;
    transition: background-color 0.3s;
}

.think-button {
    background-color: #0ea5e9;
}

.think-button:hover {
    background-color: #0284c7;
}

.reset-button {
    background-color: #ef4444;
}

.reset-button:hover {
    background-color: #dc2626;
}

.talk-button {
    background-color: #f97316;
}

.talk-button:hover {
    background-color: #ea580c;
}

.instructions-button {
    background-color: #fcd34d;
    padding: 15px;
    text-align: center;
    font-size: 16px;
    font-weight: bold;
    margin-bottom: 15px;
    border-radius: 8px;
    cursor: pointer;
    width: 100%;
}

.instructions-button:hover {
    background-color: #fbbf24;
}

/* Participants Table Styles */
.participants-list {
    background-color: #f97316;
    color: white;
    padding: 15px;
    font-size: 18px;
    font-weight: bold;
    border-radius: 8px 8px 0 0;
    position: sticky;
    top: 0;
    z-index: 10;
}

.participants-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: white;
    border-radius: 0 0 8px 8px;
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
    table-layout: fixed;
}

.participants-table thead {
    display: table;
    width: 100%;
    table-layout: fixed;
}

.participants-table tbody::-webkit-scrollbar {
    width: 6px;
}

.participants-table tbody::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.participants-table tbody::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 3px;
}

.participants-table tbody tr {
    display: table;
    width: 100%;
    table-layout: fixed;
}

.participants-table th:nth-child(1),
.participants-table td:nth-child(1) {
    width: 40px;
    max-width: 40px;
    text-align: center;
}

.participants-table th:nth-child(2),
.participants-table td:nth-child(2) {
    width: 25%;
}

.participants-table th:nth-child(3),
.participants-table td:nth-child(3) {
    width: 40%;
}

.participants-table th:nth-child(4),
.participants-table td:nth-child(4) {
    width: 80px;
    text-align: center;
}

.participants-table th:nth-child(5),
.participants-table td:nth-child(5) {
    width: 80px;
    text-align: center;
}

.participants-table th {
    background-color: #bed9f3;
    padding: 10px 4px;
    text-align: left;
    font-weight: 600;
    font-size: 16px;
}

.participants-table td {
    padding: 2px 4px;
    border-bottom: 1px solid #e5e7eb;
    vertical-align: middle;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 14px;
}

.team-name {
    font-weight: 500;
    font-size: 16px;
}

.student-name {
    font-weight: 600;
    font-size: 17px;
}

.participants-table tr:nth-child(even) {
    background-color: rgba(234, 236, 204, 0.2);
}

.participants-table tr:hover {
    background-color: rgba(249, 115, 22, 0.05);
}

/* Student row highlighting */
.student-row.active {
    background-color: rgba(249, 115, 22, 0.1) !important;
}

.student-row.completed {
    background-color: rgba(40, 167, 69, 0.1) !important;
}

.student-radio, .student-checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

/* Footer Styles */
.footer-warning {
    text-align: center;
    padding: 15px;
    background-color: white;
    color: #059669;
    font-weight: bold;
    border-top: 1px solid #e5e7eb;
}

/* Error Messages */
#access-denied, #password-incorrect, #error-message {
    background-color: #fee2e2;
    color: #b91c1c;
    padding: 15px;
    margin: 15px auto;
    border-radius: 8px;
    max-width: 500px;
    text-align: center;
    font-weight: bold;
}

/* Responsive Adjustments */
@media (max-width: 1200px) {
    .left-panel {
        flex: 0 0 450px;
    }
}

@media (max-width: 992px) {
    .flex-container {
        flex-direction: column;
    }

    .left-panel {
        flex: 0 0 auto;
        width: 100%;
        margin-bottom: 20px;
    }

    .right-panel {
        width: 100%;
    }
}

@media (max-width: 768px) {
    .title {
        font-size: 20px;
    }

    .logo img {
        height: 40px;
    }

    .timer-buttons {
        flex-direction: column;
        gap: 10px;
    }

    .timer-button {
        margin: 5px 0;
    }

    .participants-table th,
    .participants-table td {
        font-size: 14px;
        padding: 8px 0px;
    }
}
