:root {
    --primary-color: #a855f7;
    --primary-hover: #9333ea;
    --bg-color: #0f111a;
    --card-bg: rgba(30, 35, 45, 0.6);
    --glass-border: rgba(255, 255, 255, 0.05);
    --text-color: #e2e8f0;
    --text-muted: #94a3b8;
    --success-color: #10b981;
    --error-color: #ef4444;
}

body {
    margin: 0;
    padding: 0;
    background-color: #1a1a1f;
    background: url(/templates/standart/img/sky_background.png) no-repeat center center fixed;
    background-size: cover;
    font-family: 'Inter', sans-serif;
    color: var(--text-color);
    min-height: 100vh;
}

.promo-wrapper {
    max-width: 1000px;
    margin: 0 auto;
    padding: 2rem;
}

/* Nav */
.promo-nav {
    background: rgba(15, 17, 26, 0.8);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 10px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.promo-nav .logo {
    font-size: 1.25rem;
    font-weight: 700;
    color: #fff;
}

.nav-links {
    display: flex;
    gap: 15px;
}

.nav-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 0.95rem;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.nav-btn:hover {
    color: var(--text-color);
}

.nav-btn.active {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-color);
}

/* Cards */
.glass-card {
    background: var(--card-bg);
    backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.main-card {
    max-width: 500px;
    margin: 0 auto;
}

.card-header h2 {
    margin: 0 0 0.5rem 0;
    font-size: 1.8rem;
    font-weight: 700;
    background: linear-gradient(135deg, #a855f7, #3b82f6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.card-header p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Inputs & Buttons */
.input-group-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.input-group {
    display: flex;
    background: rgba(15, 17, 26, 0.5);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 6px;
    transition: border-color 0.3s ease;
}

.input-group:focus-within {
    border-color: rgba(168, 85, 247, 0.5);
}

.input-group input {
    flex: 1;
    background: transparent;
    border: none;
    padding: 0 1rem;
    color: var(--text-color);
    font-size: 1rem;
    font-family: inherit;
    outline: none;
}

.btn-primary {
    background: linear-gradient(135deg, #a855f7, #ec4899);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: opacity 0.3s ease, transform 0.1s ease;
    box-shadow: 0 4px 15px rgba(168, 85, 247, 0.3);
}

.btn-primary:hover {
    opacity: 0.9;
}

.btn-primary:active {
    transform: translateY(1px);
}

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

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-color);
    border: 1px solid var(--glass-border);
    padding: 8px 16px;
    border-radius: 8px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
}

.error-msg {
    color: var(--error-color);
    font-size: 0.85rem;
    margin-top: 5px;
    text-align: center;
}

.hidden {
    display: none !important;
}

.view-section {
    display: none;
    animation: fadeIn 0.4s ease forwards;
}

.view-section.active {
    display: block;
}

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

/* Admin Panel */
.admin-tabs {
    display: flex;
    gap: 10px;
    margin-bottom: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.admin-tab {
    background: transparent;
    color: var(--text-muted);
    border: none;
    padding: 10px 20px;
    border-radius: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.admin-tab.active {
    background: rgba(168, 85, 247, 0.15);
    color: #c084fc;
}

.admin-tab:hover:not(.active) {
    color: var(--text-color);
}

.admin-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.full-width {
    width: 100%;
    box-sizing: border-box;
}

/* Admin Form Elements */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.admin-form input[type="text"],
.admin-form input[type="number"],
.custom-select {
    width: 100%;
    background: rgba(15, 17, 26, 0.5);
    border: 1px solid var(--glass-border);
    color: var(--text-color);
    padding: 12px 16px;
    border-radius: 12px;
    font-family: inherit;
    font-size: 0.95rem;
    box-sizing: border-box;
    outline: none;
    transition: border-color 0.3s;
    height: auto !important;
    min-height: 48px;
    line-height: normal;
}

.admin-form input:focus,
.custom-select:focus {
    border-color: rgba(168, 85, 247, 0.5);
}

.custom-select option {
    background: var(--bg-color);
    color: var(--text-color);
}

.btn-group {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
}

/* Rewards Container */
.reward-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 15px;
    margin-bottom: 10px;
    animation: fadeIn 0.3s ease;
}

.reward-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-size: 0.9rem;
    color: #c084fc;
}

.btn-remove-reward {
    background: transparent;
    color: var(--error-color);
    border: none;
    cursor: pointer;
    font-size: 1.2rem;
    line-height: 1;
}

/* Admin Tables */
.table-responsive {
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.admin-table th, .admin-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid var(--glass-border);
}

.admin-table th {
    color: var(--text-muted);
    font-weight: 500;
}

.search-input {
    background: rgba(15, 17, 26, 0.5);
    border: 1px solid var(--glass-border);
    color: var(--text-color);
    padding: 8px 16px;
    border-radius: 20px;
    outline: none;
    font-family: inherit;
}

.search-input:focus {
    border-color: rgba(168, 85, 247, 0.5);
}

/* Success icon animation */
.success-icon svg {
    width: 60px;
    height: 60px;
    color: var(--success-color);
    margin-bottom: 15px;
    animation: scaleIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

@keyframes scaleIn {
    0% { transform: scale(0); }
    100% { transform: scale(1); }
}

@media (max-width: 768px) {
    .admin-grid {
        grid-template-columns: 1fr;
    }
    .promo-nav {
        flex-direction: column;
        gap: 15px;
    }
}
