@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@400;600&family=Nunito:wght@400;700&display=swap');

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: 'Nunito', sans-serif;
}

body {
    background: #f4effa; /* Pastel Purple background */
    color: #333;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Header */
header {
    background: #ffffff;
    padding: 15px 30px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 50;
}

.logo-section h1 {
    font-family: 'Fredoka', sans-serif;
    color: #6a4c93;
    font-size: 24px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.role-badge {
    background: #ffcc00;
    color: #333;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: bold;
}

.expiry-badge {
    background: #e6e6e6;
    color: #555;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
}

.hamburger {
    font-size: 24px;
    cursor: pointer;
    display: none;
}

.hamburger.visible {
    display: block;
}

/* Main Content */
.main-container {
    display: flex;
    flex: 1;
    padding: 20px;
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

.controls-section {
    flex: 1;
    background: white;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    height: fit-content;
}

.controls-section h2 {
    color: #6a4c93;
    margin-bottom: 20px;
    font-family: 'Fredoka', sans-serif;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: #555;
}

.form-group input[type="text"], .form-group input[type="file"] {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    outline: none;
}

.form-group input[type="text"]:focus {
    border-color: #6a4c93;
}

/* Colors List */
.colors-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 10px;
}

.color-tag {
    background: #6a4c93;
    color: white;
    padding: 5px 10px;
    border-radius: 15px;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.color-tag span {
    cursor: pointer;
    font-weight: bold;
}

.btn-add {
    background: #4a90e2;
    color: white;
    border: none;
    padding: 10px 15px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
}

.btn-generate {
    background: #6a4c93;
    color: white;
    border: none;
    padding: 15px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: bold;
    width: 100%;
    font-size: 16px;
    margin-top: 20px;
    transition: 0.3s;
}

.btn-generate:hover {
    background: #553a7a;
}

/* Canvas Area */
.preview-section {
    flex: 1.5;
    background: white;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    display: flex;
    flex-direction: column;
    align-items: center;
}

canvas {
    max-width: 100%;
    border: 2px dashed #ddd;
    border-radius: 10px;
    background: #fafafa;
}

/* Admin Modal */
.admin-modal-overlay {
    display: none;
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 100;
    align-items: center;
    justify-content: center;
}

.admin-modal {
    background: white;
    padding: 30px;
    border-radius: 15px;
    width: 400px;
    max-width: 90%;
    position: relative;
}

.admin-modal h2 {
    color: #6a4c93;
    margin-bottom: 20px;
    font-family: 'Fredoka', sans-serif;
}

.close-btn {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    color: #aaa;
}

.admin-modal select, .admin-modal input[type="date"] {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    outline: none;
    margin-bottom: 15px;
}

/* Responsive */
@media (max-width: 768px) {
    .main-container {
        flex-direction: column;
    }
    .user-info {
        display: none; /* Hide badges on mobile header to save space, show in menu */
    }
}

/* Footer */
footer {
    text-align: center;
    padding: 20px;
    background: #fff;
    color: #666;
    margin-top: auto;
    font-size: 14px;
}
