/* ============================================
   GOLDEN CUP — KONTROL PANELİ STİLLERİ
   ============================================ */

/* Layout */
.control-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 20px;
    padding: 20px;
    max-width: 1600px;
    margin: 0 auto;
    min-height: calc(100vh - 55px);
}

.control-right {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* ====== SECTION CARDS ====== */
.control-section {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: var(--transition);
    box-shadow: var(--shadow-card);
}

.control-section:hover {
    border-color: var(--border-glow);
}

.section-header {
    padding: 14px 18px;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.12), rgba(212, 175, 55, 0.03));
    border-bottom: 1px solid var(--border-color);
}

.section-header h2 {
    font-size: 1.2rem;
    color: var(--gold);
    letter-spacing: 3px;
}

.section-subtitle {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 2px;
}

/* ====== TEAM GRID ====== */
.team-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    padding: 14px;
    max-height: calc(100vh - 120px);
    overflow-y: auto;
}

.team-card {
    background: rgba(13, 26, 18, 0.55);
    border: 1px solid rgba(212, 175, 55, 0.12);
    border-radius: var(--radius-md);
    padding: 10px 8px;
    text-align: center;
    transition: var(--transition);
    position: relative;
}

.team-card:hover {
    border-color: var(--gold);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(212, 175, 55, 0.15);
}

.team-card .team-number {
    position: absolute;
    top: 5px;
    left: 7px;
    font-family: 'Bebas Neue', sans-serif;
    font-size: 0.75rem;
    color: var(--gold-dark);
    letter-spacing: 1px;
    opacity: 0.7;
}

.team-logo-preview {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: 2px solid var(--border-color);
    margin: 6px auto 8px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 0, 0, 0.35);
    cursor: pointer;
    transition: var(--transition);
}

.team-logo-preview:hover {
    border-color: var(--gold);
    box-shadow: 0 0 14px var(--gold-glow);
    transform: scale(1.08);
}

.team-logo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.team-logo-preview .placeholder-icon {
    font-size: 1.3rem;
    opacity: 0.35;
}

.team-card input[type="text"] {
    width: 100%;
    padding: 5px 6px;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(212, 175, 55, 0.15);
    border-radius: var(--radius-sm);
    color: var(--text-light);
    font-family: 'Outfit', sans-serif;
    font-size: 0.75rem;
    text-align: center;
    transition: var(--transition);
    outline: none;
}

.team-card input[type="text"]:focus {
    border-color: var(--gold);
    background: rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 8px rgba(212, 175, 55, 0.15);
}

.team-card input[type="file"] {
    display: none;
}

/* ====== BUTTONS ====== */
.fixture-buttons {
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-row {
    display: flex;
    gap: 10px;
}

.btn-row .btn {
    flex: 1;
}

.btn {
    padding: 11px 20px;
    border: none;
    border-radius: var(--radius-md);
    font-family: 'Bebas Neue', sans-serif;
    font-size: 1.05rem;
    letter-spacing: 2px;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
    user-select: none;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08), transparent);
    transition: left 0.6s ease;
}

.btn:hover:not(:disabled)::before {
    left: 100%;
}

.btn:active:not(:disabled) {
    transform: scale(0.97);
}

.btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
    filter: grayscale(0.5);
}

.btn-primary {
    background: linear-gradient(135deg, var(--forest-green), var(--dark-green));
    color: var(--text-light);
    border: 1px solid var(--emerald);
}

.btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, var(--emerald), var(--forest-green));
    box-shadow: 0 0 20px rgba(61, 139, 94, 0.35);
}

.btn-gold {
    background: linear-gradient(135deg, var(--gold), var(--gold-dark));
    color: var(--deep-green);
    border: 1px solid var(--gold-light);
    font-weight: 700;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.2);
}

.btn-gold:hover:not(:disabled) {
    background: linear-gradient(135deg, var(--gold-light), var(--gold));
    box-shadow: var(--shadow-gold);
    transform: translateY(-1px);
}

.btn-warning {
    background: linear-gradient(135deg, rgba(243, 156, 18, 0.25), var(--warning-bg));
    color: var(--warning);
    border: 1px solid rgba(243, 156, 18, 0.35);
}

.btn-warning:hover:not(:disabled) {
    background: linear-gradient(135deg, rgba(243, 156, 18, 0.35), rgba(243, 156, 18, 0.2));
    box-shadow: 0 0 15px rgba(243, 156, 18, 0.25);
}

.btn-danger {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.25), var(--danger-bg));
    color: var(--danger);
    border: 1px solid rgba(231, 76, 60, 0.35);
}

.btn-danger:hover:not(:disabled) {
    background: linear-gradient(135deg, rgba(231, 76, 60, 0.35), rgba(231, 76, 60, 0.2));
    box-shadow: 0 0 15px rgba(231, 76, 60, 0.25);
}

.btn-lg {
    padding: 14px 28px;
    font-size: 1.25rem;
    letter-spacing: 3px;
}

.btn-icon {
    font-size: 1em;
}

/* ====== DRAW FORM ====== */
.draw-form {
    padding: 16px 18px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.form-group label {
    font-family: 'Bebas Neue', sans-serif;
    font-size: 0.95rem;
    color: var(--gold);
    letter-spacing: 2px;
}

.form-select {
    padding: 10px 14px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-light);
    font-family: 'Outfit', sans-serif;
    font-size: 0.95rem;
    cursor: pointer;
    transition: var(--transition);
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23D4AF37' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
}

.form-select:focus {
    border-color: var(--gold);
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.15);
}

.form-select:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

.form-select option {
    background: var(--deep-green);
    color: var(--text-light);
}

/* ====== STATUS PANEL ====== */
.status-info {
    padding: 14px 18px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.status-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-sm);
    gap: 8px;
}

.status-label {
    color: var(--text-muted);
    font-size: 0.85rem;
    white-space: nowrap;
}

.status-value {
    font-family: 'Bebas Neue', sans-serif;
    color: var(--gold);
    font-size: 1.05rem;
    letter-spacing: 1px;
}

/* Progress Bar */
.progress-bar-wrapper {
    flex: 1;
    height: 6px;
    background: rgba(0, 0, 0, 0.3);
    border-radius: 3px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--emerald), var(--gold));
    border-radius: 3px;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ====== DRAW HISTORY ====== */
.draw-history {
    padding: 0 18px 16px;
}

.draw-history h3 {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 8px;
    letter-spacing: 2px;
}

.history-list {
    max-height: 180px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.history-empty {
    text-align: center;
    color: var(--text-muted);
    font-size: 0.8rem;
    padding: 12px;
    opacity: 0.6;
    font-style: italic;
}

.history-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 7px 11px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: var(--radius-sm);
    font-size: 0.82rem;
    border-left: 3px solid var(--gold-dark);
    animation: historySlideIn 0.3s ease;
}

@keyframes historySlideIn {
    from { opacity: 0; transform: translateX(-15px); }
    to   { opacity: 1; transform: translateX(0); }
}

.history-item .history-letter {
    font-family: 'Bebas Neue', sans-serif;
    color: var(--gold);
    font-size: 1.05rem;
    min-width: 20px;
    text-align: center;
}

.history-item .history-team {
    color: var(--text-light);
    flex: 1;
}

.history-item .history-team-logo {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid var(--border-color);
}

/* ====== RESPONSIVE ====== */
@media (max-width: 1100px) {
    .control-layout {
        grid-template-columns: 1fr;
    }
    .team-grid {
        max-height: 400px;
    }
}

@media (max-width: 700px) {
    .team-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
