@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;800&display=swap');

* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    width: 100%;
    overflow-x: hidden;
}

body {
    font-family: 'Inter', sans-serif;
    background: linear-gradient(120deg, #e0e7ff 0%, #f0fdfa 100%);
}

/* Admin Grid Form - Responsive */
.admin-grid-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: #f8fafc;
    border-radius: 0.75rem;
    width: 100%;
    box-sizing: border-box;
}

.admin-grid-form .form-label {
    display: block;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.admin-grid-form .full-width {
    grid-column: 1 / -1;
}

.header {
    background: linear-gradient(90deg, var(--primary-color, #2563eb) 0%, #60a5fa 100%);
    color: #fff;
    padding: 2rem 0;
    text-align: center;
    font-size: 2.2rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    letter-spacing: 0.05em;
    box-shadow: 0 4px 24px 0 rgba(31, 38, 135, 0.18);
}

/* Navigation Menu */
.nav-menu {
    background: rgba(255,255,255,0.9);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255,255,255,0.3);
    padding: 1rem 0;
    display: flex;
    justify-content: center;
    gap: 2rem;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.nav-btn {
    background: rgba(255,255,255,0.7);
    border: 2px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-btn:hover {
    background: rgba(255,255,255,0.9);
    border-color: #3b82f6;
    color: #3b82f6;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
}

.nav-btn.active {
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    border-color: #1d4ed8;
    color: white;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* Mode Cards for Landing Page */
.mode-card {
    background: white;
    border-radius: 1rem;
    padding: 2rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    cursor: pointer;
    border: 2px solid transparent;
}

.mode-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.mode-card.practice {
    border-color: #3b82f6;
}

.mode-card.practice:hover {
    border-color: #2563eb;
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.2);
}

.mode-card.exam {
    border-color: #10b981;
}

.mode-card.exam:hover {
    border-color: #059669;
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.2);
}

.mode-card.admin {
    border-color: #6b7280;
}

.mode-card.admin:hover {
    border-color: #4b5563;
    box-shadow: 0 8px 25px rgba(107, 114, 128, 0.2);
}

/* Practice/Exam Specific Cards */
.practice-catalog-card {
    background: white;
    border-radius: 0.75rem;
    padding: 1.5rem;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
    cursor: pointer;
}

.practice-catalog-card:hover {
    border-color: #3b82f6;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.1);
    transform: translateY(-2px);
}

.exam-card {
    background: white;
    border-radius: 0.75rem;
    padding: 1.5rem;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
    cursor: pointer;
}

.exam-card:hover {
    border-color: #10b981;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.1);
    transform: translateY(-2px);
}

/* Admin Panel Styles */
.admin-tabs {
    display: flex;
    gap: 0.5rem;
    background: white;
    border-radius: 1rem;
    padding: 0.5rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.admin-tab {
    padding: 0.75rem 1.5rem;
    border: none;
    background: none;
    border-radius: 0.75rem;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    color: #64748b;
}

.admin-tab:hover {
    background: #f8fafc;
}

.admin-tab.active {
    background: #374151;
    color: white;
    box-shadow: 0 2px 8px rgba(55, 65, 81, 0.3);
}

/* Utility Classes für responsive Layouts */
.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.flex-column {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.flex-wrap {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.grid-auto {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

/* Responsive Overrides */
@media (max-width: 768px) {
    .flex-between {
        flex-direction: column;
        align-items: stretch;
    }
    
    .grid-auto {
        grid-template-columns: 1fr;
    }
}

.admin-item {
    background: #f8fafc;
    border-radius: 0.75rem;
    padding: 1.25rem;
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.admin-item:hover {
    border-color: #cbd5e1;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

/* Status Badges */
.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.status-active {
    background: #dcfdf7;
    color: #065f46;
}

.status-inactive {
    background: #f3f4f6;
    color: #374151;
}

.status-passed {
    background: #dcfdf7;
    color: #065f46;
}

.status-failed {
    background: #fef2f2;
    color: #991b1b;
}

/* Exam Warning */
.exam-warning {
    background: #fffbeb;
    border: 1px solid #fed7aa;
    border-radius: 0.75rem;
    padding: 1rem;
}

/* Button Variations */
.btn-large {
    padding: 1rem 2rem;
    font-size: 1.125rem;
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
}

.btn-danger {
    background: #ef4444;
    color: white;
    border: none;
    border-radius: 0.5rem;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.btn-danger:hover {
    background: #dc2626;
}

/* Input Styles */
.input-main {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e2e8f0;
    border-radius: 0.5rem;
    font-size: 1rem;
    transition: border-color 0.2s ease;
    background: white;
    box-sizing: border-box;
    max-width: 100%;
}

.input-main:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

/* Text Center */
.text-center {
    text-align: center;
}

/* Admin Section */
.admin-section {
    width: 100%;
}

/* Hidden utility */
.hidden {
    display: none !important;
}

.glass {
    background: rgba(255,255,255,0.8);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.18);
    backdrop-filter: blur(8px);
    border-radius: 1.2rem;
    border: 1px solid rgba(255,255,255,0.3);
    margin: 2rem auto;
    padding: 2.5rem 2rem;
    width: 90%;
    max-width: 1200px;
    min-height: calc(100vh - 300px);
    box-sizing: border-box;
    overflow-x: hidden;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-menu {
        gap: 1rem;
        padding: 0.75rem 1rem;
        flex-wrap: wrap;
        width: 100%;
        box-sizing: border-box;
    }
    
    .nav-btn {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
        box-sizing: border-box;
    }
    
    .glass {
        width: 95%;
        margin: 1rem auto;
        padding: 1.5rem 1rem;
        box-sizing: border-box;
        border-radius: 1rem;
        min-height: calc(100vh - 220px);
    }
    
    .header {
        padding: 1.5rem 1rem;
        font-size: 1.8rem;
    }
    
    footer {
        padding: 0.75rem 1rem;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .glass {
        width: 98%;
        margin: 0.5rem auto;
        padding: 1rem 0.75rem;
        border-radius: 0.8rem;
        min-height: calc(100vh - 100px);
    }
    
    .header {
        padding: 1rem;
        font-size: 1.5rem;
    }
    
    .catalog-title {
        font-size: 1.5rem;
        margin-bottom: 1.5rem;
    }
}

.catalog-card {
    background: #fff;
    border-radius: 1rem;
    box-shadow: 0 2px 12px 0 rgba(59,130,246,0.08);
    border: 1px solid #dbeafe;
    margin-bottom: 2rem;
    padding: 1.5rem 1.2rem;
    transition: box-shadow 0.2s;
}
.catalog-card:hover {
    box-shadow: 0 4px 24px 0 rgba(59,130,246,0.18);
}

.catalog-name {
    font-size: 1.2rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 1rem;
}

/* Responsive Catalog Cards */
@media (max-width: 768px) {
    .catalog-card {
        padding: 1rem;
        margin-bottom: 1.5rem;
        border-radius: 0.8rem;
    }
    
    .catalog-name {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
    }
}

@media (max-width: 480px) {
    .catalog-card {
        padding: 0.75rem;
        margin-bottom: 1rem;
    }
    
    .catalog-name {
        font-size: 1rem;
        margin-bottom: 0.5rem;
    }
}

.btn-main {
    background: #2563eb;
    color: #fff;
    padding: 0.7rem 1.5rem;
    border-radius: 0.7rem;
    font-weight: 600;
    border: none;
    box-shadow: 0 2px 8px 0 rgba(59,130,246,0.08);
    cursor: pointer;
    transition: background 0.2s;
    width: 100%;
    max-width: 200px;
    box-sizing: border-box;
}
.btn-main:hover {
    background: #1d4ed8;
}

.btn-secondary {
    background: #f1f5f9;
    color: #2563eb;
    padding: 0.5rem 1.2rem;
    border-radius: 0.5rem;
    font-weight: 600;
    border: none;
    margin-bottom: 1.5rem;
    cursor: pointer;
    transition: background 0.2s;
    box-sizing: border-box;
}
.btn-secondary:hover {
    background: #e0e7ef;
}

/* Responsive Buttons */
@media (max-width: 768px) {
    .btn-main {
        padding: 0.6rem 1.2rem;
        font-size: 0.95rem;
        max-width: none;
        width: 100%;
    }
    
    .btn-secondary {
        padding: 0.5rem 1rem;
        font-size: 0.9rem;
        width: 100%;
        margin-bottom: 1rem;
    }
}

@media (max-width: 480px) {
    .btn-main {
        padding: 0.55rem 1rem;
        font-size: 0.9rem;
        border-radius: 0.5rem;
    }
    
    .btn-secondary {
        padding: 0.45rem 0.8rem;
        font-size: 0.85rem;
        border-radius: 0.4rem;
    }
}

.question-block {
    background: #f8fafc;
    border-radius: 0.8rem;
    border: 1px solid #dbeafe;
    margin-bottom: 1.5rem;
    padding: 1.2rem 1rem;
    box-shadow: 0 1px 4px 0 rgba(59,130,246,0.04);
}
.question-title {
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.7rem;
    font-size: 1.1rem;
}
.options-list label {
    display: flex;
    align-items: center;
    margin-bottom: 0.5rem;
    cursor: pointer;
}
.options-list input[type="radio"] {
    accent-color: #2563eb;
    margin-right: 0.7rem;
    transform: scale(1.2);
}

/* Responsive Questions */
@media (max-width: 768px) {
    .question-block {
        padding: 1rem 0.8rem;
        margin-bottom: 1.25rem;
        border-radius: 0.7rem;
    }
    
    .question-title {
        font-size: 1rem;
        margin-bottom: 0.6rem;
    }
    
    .options-list label {
        margin-bottom: 0.4rem;
        font-size: 0.95rem;
    }
    
    .options-list input[type="radio"] {
        margin-right: 0.5rem;
        transform: scale(1.1);
    }
}

@media (max-width: 480px) {
    .question-block {
        padding: 0.8rem 0.6rem;
        margin-bottom: 1rem;
    }
    
    .question-title {
        font-size: 0.95rem;
        margin-bottom: 0.5rem;
        line-height: 1.4;
    }
    
    .options-list label {
        margin-bottom: 0.35rem;
        font-size: 0.9rem;
        line-height: 1.3;
    }
}
.input-main {
    border: 1px solid #93c5fd;
    border-radius: 0.5rem;
    padding: 0.6rem 1rem;
    width: 100%;
    font-size: 1rem;
    margin-top: 0.2rem;
    transition: border 0.2s;
    box-sizing: border-box;
}
.input-main:focus {
    border: 1.5px solid #2563eb;
    outline: none;
}

/* Responsive Inputs */
@media (max-width: 768px) {
    .input-main {
        padding: 0.55rem 0.8rem;
        font-size: 0.95rem;
        border-radius: 0.4rem;
    }
}

@media (max-width: 480px) {
    .input-main {
        padding: 0.5rem 0.7rem;
        font-size: 0.9rem;
        border-radius: 0.35rem;
    }
}
.result-block {
    margin-top: 2.5rem;
    background: linear-gradient(120deg, #bbf7d0 0%, #dbeafe 100%);
    border-radius: 1rem;
    box-shadow: 0 2px 12px 0 rgba(34,197,94,0.08);
    border: 1px solid #bbf7d0;
    padding: 2rem 1.5rem;
}
.result-block .score {
    font-weight: 700;
    color: #166534;
    font-size: 1.2rem;
    margin-bottom: 1.2rem;
}
.result-block ul {
    margin-top: 1rem;
    padding-left: 1.2rem;
}
.result-block li {
    margin-bottom: 0.7rem;
    font-size: 1rem;
    display: flex;
    align-items: center;
    gap: 0.7rem;
}
.result-block .correct {
    color: #16a34a;
    font-weight: 700;
    font-size: 1.2rem;
}
.result-block .wrong {
    color: #dc2626;
    font-weight: 700;
    font-size: 1.2rem;
}
footer {
    background: #f1f5f9;
    text-align: center;
    padding: 1rem 0;
    font-size: 0.95rem;
    color: #64748b;
    box-shadow: 0 -2px 8px 0 rgba(59,130,246,0.04);
}

/* Admin-Panel Styles */
.admin-section {
    background: rgba(255,255,255,0.9);
    border-radius: 1rem;
    border: 1px solid rgba(255,255,255,0.3);
    margin: 0 0 2rem 0;
    padding: 1.5rem;
    box-shadow: 0 4px 16px 0 rgba(31, 38, 135, 0.12);
    backdrop-filter: blur(4px);
    width: 100%;
    box-sizing: border-box;
}

.admin-section h3 {
    color: #1e293b;
    font-weight: 600;
    font-size: 1.25rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e2e8f0;
}

.admin-section form {
    display: grid;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.admin-section form input,
.admin-section form select {
    border: 1px solid #cbd5e1;
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    transition: all 0.2s;
    background: rgba(255,255,255,0.8);
}

.admin-section form input:focus,
.admin-section form select:focus {
    border: 2px solid #2563eb;
    outline: none;
    background: rgba(255,255,255,1);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.admin-section ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.admin-section li {
    background: rgba(248, 250, 252, 0.8);
    border: 1px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 1rem;
    margin-bottom: 0.75rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s;
    backdrop-filter: blur(2px);
}

.admin-section li:hover {
    background: rgba(255,255,255,0.9);
    box-shadow: 0 2px 8px 0 rgba(59,130,246,0.08);
    transform: translateY(-1px);
}

.admin-section li b {
    color: #1e293b;
    font-weight: 600;
}

.admin-section button {
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    border: none;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.9rem;
}

/* Responsive Admin Styles */
@media (max-width: 768px) {
    .admin-section {
        padding: 1rem;
        margin-bottom: 1.5rem;
        border-radius: 0.8rem;
    }
    
    .admin-section h3 {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
    }
    
    .admin-section form {
        gap: 0.75rem;
    }
    
    .admin-section form input,
    .admin-section form select {
        padding: 0.6rem 0.8rem;
        font-size: 0.95rem;
    }
    
    .admin-section li {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.75rem;
        padding: 0.75rem;
    }
    
    .admin-section button {
        padding: 0.4rem 0.8rem;
        font-size: 0.85rem;
        width: 100%;
        margin-bottom: 0.25rem;
    }
}

@media (max-width: 480px) {
    .admin-section {
        padding: 0.75rem;
        margin-bottom: 1rem;
    }
    
    .admin-section h3 {
        font-size: 1rem;
    }
    
    .admin-section form input,
    .admin-section form select {
        padding: 0.5rem 0.6rem;
        font-size: 0.9rem;
    }
}

.report-item {
    background: rgba(255,255,255,0.9) !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 0.75rem !important;
    padding: 1.25rem !important;
    margin: 1rem 0 !important;
    box-shadow: 0 2px 8px 0 rgba(59,130,246,0.06) !important;
    backdrop-filter: blur(4px);
    transition: all 0.2s;
}

.report-item:hover {
    box-shadow: 0 4px 16px 0 rgba(59,130,246,0.12) !important;
    transform: translateY(-2px);
}

.success-message {
    background: linear-gradient(120deg, #dcfce7 0%, #dbeafe 100%);
    border: 1px solid #bbf7d0;
    border-radius: 1rem;
    padding: 2rem;
    text-align: center;
    box-shadow: 0 4px 16px 0 rgba(34,197,94,0.08);
}

.success-message h3 {
    color: #166534;
    font-weight: 700;
    margin-bottom: 1rem;
}

.success-message p {
    color: #15803d;
    margin-bottom: 1.5rem;
}

.input-group {
    margin-bottom: 1.5rem;
}

.input-group label {
    display: block;
    font-weight: 600;
    color: #374151;
    margin-bottom: 0.5rem;
}

.exam-mode-container {
    background: rgba(248, 250, 252, 0.8);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
    border: 1px solid #e2e8f0;
}

.questions-details {
    margin-top: 1.5rem;
}

.questions-details h5 {
    margin: 0 0 1rem 0;
    color: #1e293b;
    font-weight: 600;
}

.questions-details p {
    margin: 0.5rem 0;
    color: #475569;
    line-height: 1.5;
}

/* Mobile-specific responsive styles */
@media (max-width: 768px) {
    .exam-mode-container {
        padding: 1rem;
        margin-bottom: 1.5rem;
        border-radius: 0.8rem;
    }
    
    .questions-details {
        margin-top: 1rem;
    }
    
    .questions-details h5 {
        font-size: 0.95rem;
        margin-bottom: 0.75rem;
    }
    
    .questions-details p {
        font-size: 0.9rem;
        line-height: 1.4;
    }
    
    .report-item {
        padding: 1rem !important;
        margin: 0.75rem 0 !important;
    }
    
    .success-message {
        padding: 1.5rem !important;
    }
    
    .success-message h3 {
        font-size: 1.1rem;
        margin-bottom: 0.75rem;
    }
    
    .success-message p {
        font-size: 0.95rem;
        margin-bottom: 1.25rem;
    }
}

@media (max-width: 480px) {
    .exam-mode-container {
        padding: 0.75rem;
        margin-bottom: 1rem;
        border-radius: 0.6rem;
    }
    
    .questions-details h5 {
        font-size: 0.9rem;
        margin-bottom: 0.5rem;
    }
    
    .questions-details p {
        font-size: 0.85rem;
        margin: 0.4rem 0;
    }
    
    .report-item {
        padding: 0.75rem !important;
        margin: 0.5rem 0 !important;
        border-radius: 0.5rem !important;
    }
    
    .success-message {
        padding: 1rem !important;
    }
    
    .success-message h3 {
        font-size: 1rem;
        margin-bottom: 0.5rem;
    }
    
    .success-message p {
        font-size: 0.9rem;
        margin-bottom: 1rem;
    }
}

/* ===== ANIMATION STYLES ===== */

/* Keyframe Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes bounceIn {
    0% {
        opacity: 0;
        transform: scale(0.3);
    }
    50% {
        opacity: 1;
        transform: scale(1.05);
    }
    70% {
        transform: scale(0.9);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes pulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Enhanced Card Styles with Hover Effects */
.catalog-card {
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid transparent;
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    width: 100%;
    box-sizing: border-box;
}

.catalog-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.6s;
}

.catalog-card:hover::before {
    left: 100%;
}

.catalog-card:hover {
    /* Subtle hover - only shadow change, no transform */
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
    border-color: #93c5fd;
}

.catalog-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
}

.catalog-name {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.catalog-questions {
    color: #64748b;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.catalog-btn {
    transform: translateY(0);
    transition: transform 0.2s ease;
}

.catalog-card:hover .catalog-btn {
    transform: translateY(-2px);
}

/* Grid Layout for Catalogs */
.catalog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

/* Enhanced Question Blocks */
.question-block {
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid #e2e8f0;
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
    position: relative;
}

/* Removed aggressive hover effect on question blocks */

.question-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid #e2e8f0;
    gap: 1rem;
    flex-wrap: wrap;
    box-sizing: border-box;
}

.question-number {
    background: #3b82f6;
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 0.5rem;
    font-size: 0.9rem;
    font-weight: 600;
}

.question-type {
    background: #f1f5f9;
    color: #64748b;
    padding: 0.25rem 0.75rem;
    border-radius: 0.5rem;
    font-size: 0.8rem;
}

/* Enhanced Options */
.option-label {
    display: flex;
    align-items: center;
    padding: 0.75rem;
    margin: 0.5rem 0;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s ease;
    background: rgba(248, 250, 252, 0.8);
    border: 1px solid #e2e8f0;
}

.option-label:hover {
    background: rgba(59, 130, 246, 0.1);
    border-color: #3b82f6;
    /* Removed translateX - too aggressive when nested */
}

.option-label input[type="radio"] {
    margin-right: 0.75rem;
    transform: scale(1.2);
}

.option-text {
    flex: 1;
}

.option-checkmark {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 2px solid #d1d5db;
    transition: all 0.2s ease;
}

.option-label input[type="radio"]:checked + .option-text + .option-checkmark {
    background: #3b82f6;
    border-color: #3b82f6;
}

/* Text Input Enhancement */
.text-answer {
    width: 100%;
    padding: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 0.75rem;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.9);
}

.text-answer:focus {
    border-color: #3b82f6;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.15);
}

/* Enhanced Results Display */
.result-block {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 1rem;
    padding: 2rem;
    margin-top: 2rem;
    border: 2px solid #e2e8f0;
    position: relative;
    overflow: hidden;
}

.result-block.passed {
    border-color: #10b981;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(255, 255, 255, 0.95));
}

.result-block.failed {
    border-color: #ef4444;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(255, 255, 255, 0.95));
}

.score-header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.score-icon {
    font-size: 4rem;
    margin-right: 1rem;
}

.score-text {
    text-align: center;
}

.score-main {
    font-size: 2rem;
    font-weight: 700;
    color: #1e293b;
}

.score-percentage {
    font-size: 1.25rem;
    color: #64748b;
}

.result-status {
    text-align: center;
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 2rem;
    padding: 1rem;
    border-radius: 0.75rem;
}

.result-block.passed .result-status {
    color: #10b981;
    background: rgba(16, 185, 129, 0.1);
}

.result-block.failed .result-status {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
}

.detailed-results {
    margin-top: 2rem;
}

.result-item {
    display: flex;
    align-items: center;
    padding: 1rem;
    margin: 0.5rem 0;
    border-radius: 0.5rem;
    background: rgba(248, 250, 252, 0.8);
    border: 1px solid #e2e8f0;
}

.result-icon {
    margin-right: 1rem;
    font-size: 1.5rem;
    font-weight: bold;
}

.result-icon.correct {
    color: #10b981;
}

.result-icon.wrong {
    color: #ef4444;
}

.result-details {
    flex: 1;
}

.result-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

/* Loading Animations */
.loading-container {
    text-align: center;
    padding: 4rem 2rem;
    color: #64748b;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f4f6;
    border-top: 4px solid #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

.loading-spinner.small {
    width: 20px;
    height: 20px;
    border-width: 2px;
    display: inline-block;
    margin-right: 0.5rem;
}

/* Success/Error Overlays */
.success-overlay, .error-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.success-overlay.show, .error-overlay.show {
    opacity: 1;
}

.success-popup, .error-popup {
    background: white;
    padding: 2rem;
    border-radius: 1rem;
    text-align: center;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    transform: scale(0.8);
    transition: transform 0.3s ease;
}

.success-overlay.show .success-popup,
.error-overlay.show .error-popup {
    transform: scale(1);
}

.success-icon, .error-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

/* Breadcrumb Navigation */
.breadcrumb {
    margin-bottom: 1.5rem;
    padding: 0.75rem;
    background: rgba(248, 250, 252, 0.8);
    border-radius: 0.5rem;
    color: #64748b;
}

.btn-link {
    background: none;
    border: none;
    color: #3b82f6;
    text-decoration: none;
    cursor: pointer;
    padding: 0;
    font-size: inherit;
    transition: color 0.2s ease;
}

.btn-link:hover {
    color: #1e40af;
    text-decoration: underline;
}

/* Enhanced Exam Mode */
.exam-mode-container {
    background: rgba(248, 250, 252, 0.9);
    border: 2px solid #e2e8f0;
    border-radius: 1rem;
    padding: 2rem;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

.exam-mode-intro {
    text-align: center;
    margin-bottom: 2rem;
    padding: 1rem;
    background: rgba(59, 130, 246, 0.1);
    border-radius: 0.75rem;
    color: #1e40af;
}

.exam-start-btn {
    width: 100%;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    font-weight: 600;
    transition: all 0.3s ease;
}

.exam-start-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.exam-start-btn:not(:disabled):hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(59, 130, 246, 0.25);
}

/* Active Exam Styles */
.active-exam-container {
    border: 2px solid #3b82f6;
    border-radius: 1rem;
    padding: 2rem;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05), rgba(255, 255, 255, 0.95));
    margin-top: 2rem;
}

.exam-header {
    text-align: center;
    padding: 1.5rem;
    border-bottom: 2px solid #e2e8f0;
    margin-bottom: 2rem;
}

.exam-meta {
    display: flex;
    justify-content: center;
    gap: 2rem;
    margin-top: 1rem;
    color: #64748b;
    font-size: 0.9rem;
}

.active-exam-form {
    margin-top: 2rem;
}

.submit-section {
    text-align: center;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 2px solid #e2e8f0;
}

.submit-btn {
    padding: 1rem 3rem;
    font-size: 1.2rem;
    font-weight: 600;
    background: linear-gradient(135deg, #10b981, #059669);
    border: none;
    color: white;
    border-radius: 0.75rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submit-btn:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(16, 185, 129, 0.3);
}

.submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.btn-icon {
    margin-right: 0.5rem;
}

/* Enhanced Admin Styles */
.admin-item {
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.admin-item:hover {
    border-color: #3b82f6;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.admin-item-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-item-info {
    flex: 1;
}

.admin-item-meta {
    color: #64748b;
    font-size: 0.9rem;
    margin-top: 0.25rem;
}

.admin-item-actions {
    display: flex;
    gap: 0.5rem;
}

/* Enhanced Exam Item Styles */
.admin-exam-item {
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid #e2e8f0;
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.admin-exam-item.active {
    border-left: 6px solid #10b981;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.05), rgba(255, 255, 255, 0.95));
}

.admin-exam-item.closed {
    border-left: 6px solid #ef4444;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.05), rgba(255, 255, 255, 0.95));
}

.exam-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.exam-status {
    padding: 0.25rem 0.75rem;
    border-radius: 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
}

.exam-status.active {
    background: #10b981;
    color: white;
}

.exam-status.closed {
    background: #ef4444;
    color: white;
}

.exam-item-details {
    display: flex;
    gap: 2rem;
    margin-bottom: 1rem;
    color: #64748b;
    font-size: 0.9rem;
}

.exam-item-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Question Item Styles */
.admin-question-item {
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.admin-question-item:hover {
    border-color: #3b82f6;
    transform: translateX(5px);
}

.question-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.question-type-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
    color: white;
}

.question-type-badge.multiple_choice {
    background: #3b82f6;
}

.question-type-badge.text {
    background: #8b5cf6;
}

.question-content {
    margin-bottom: 1rem;
}

.question-text {
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: #1e293b;
}

.question-options {
    color: #64748b;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.question-answer {
    color: #059669;
    font-size: 0.9rem;
}

.question-actions {
    text-align: right;
}

/* Button Enhancements */
.btn-main, .btn-secondary, .btn-danger {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-main::before, .btn-secondary::before, .btn-danger::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-main:hover::before, .btn-secondary:hover::before, .btn-danger:hover::before {
    width: 300px;
    height: 300px;
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    border: none;
}

.btn-danger:hover {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(239, 68, 68, 0.3);
}

/* Report Styles */
.reports-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e2e8f0;
}

.reports-list {
    margin-top: 1rem;
}

.report-item {
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.report-item:hover {
    border-color: #3b82f6;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.report-summary {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.report-user {
    flex: 1;
}

.report-date {
    color: #64748b;
    font-size: 0.9rem;
    margin-top: 0.25rem;
}

.report-score {
    text-align: center;
    margin: 0 2rem;
}

.score-display {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1e293b;
}

.score-percentage {
    color: #64748b;
    font-size: 0.9rem;
}

/* Report Details */
.report-details {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 1rem;
    padding: 2rem;
}

.report-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e2e8f0;
}

.report-summary-card {
    background: rgba(248, 250, 252, 0.8);
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.summary-item {
    color: #64748b;
}

.detail-question {
    border: 2px solid #e2e8f0;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.detail-question.correct {
    border-left: 6px solid #10b981;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.05), rgba(255, 255, 255, 0.95));
}

.detail-question.incorrect {
    border-left: 6px solid #ef4444;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.05), rgba(255, 255, 255, 0.95));
}

.detail-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.result-badge {
    padding: 0.25rem 0.75rem;
    border-radius: 0.5rem;
    font-size: 0.8rem;
    font-weight: 600;
}

.result-badge.correct {
    background: #10b981;
    color: white;
}

.result-badge.incorrect {
    background: #ef4444;
    color: white;
}

.detail-content {
    margin-top: 1rem;
}

.detail-question-text {
    font-weight: 600;
    margin-bottom: 1rem;
    color: #1e293b;
}

.detail-options {
    color: #64748b;
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.detail-answers {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: 1rem;
}

.user-answer, .correct-answer {
    padding: 0.75rem;
    border-radius: 0.5rem;
    background: rgba(248, 250, 252, 0.8);
}

.user-answer span.correct, .correct-answer span.correct {
    color: #10b981;
    font-weight: 600;
}

.user-answer span.incorrect {
    color: #ef4444;
    font-weight: 600;
}

/* Success Message Styles */
.success-message {
    text-align: center;
    padding: 3rem 2rem;
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(255, 255, 255, 0.95));
    border: 2px solid #10b981;
    border-radius: 1rem;
    margin-top: 2rem;
}

.success-message .success-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    display: block;
}

.success-message h3 {
    color: #059669;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.success-message p {
    color: #64748b;
    margin-bottom: 2rem;
    font-size: 1.1rem;
}

.success-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* Responsive Enhancements */
@media (max-width: 768px) {
    .catalog-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .exam-meta {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .admin-item-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .admin-item-actions {
        width: 100%;
        justify-content: center;
    }
    
    .exam-item-actions {
        justify-content: center;
    }
    
    .report-summary {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .report-score {
        margin: 0;
    }
    
    .detail-answers {
        grid-template-columns: 1fr;
    }
    
    .success-actions {
        flex-direction: column;
    }
}

@media (max-width: 480px) {
    .question-header {
        flex-direction: column;
        gap: 0.5rem;
        align-items: flex-start;
    }
    
    .exam-item-details {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .reports-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
}

/* Mobile Responsive Fixes für Admin-Formulare */
@media (max-width: 768px) {
    /* Admin Grid Form - wird zu einer Spalte */
    .admin-grid-form {
        display: flex;
        flex-direction: column;
        gap: 1rem;
        width: 100%;
        box-sizing: border-box;
        padding: 0.75rem;
    }
    
    .admin-grid-form .full-width {
        grid-column: auto;
    }
    
    /* Ensure inputs don't overflow on mobile */
    .admin-grid-form input,
    .admin-grid-form select,
    .admin-grid-form textarea {
        width: 100%;
        box-sizing: border-box;
        font-size: 16px; /* Prevent iOS zoom */
        max-width: 100%;
    }
    
    /* Navigation responsive */
    .nav-menu {
        flex-wrap: wrap;
        gap: 0.5rem;
        padding: 0.75rem;
        width: 100%;
        box-sizing: border-box;
    }
    
    .nav-btn {
        font-size: 0.875rem;
        padding: 0.5rem 1rem;
    }
    
    /* Header responsive */
    .header {
        padding: 1rem;
        font-size: 1.25rem;
    }
    
    /* Labels kleiner auf mobil */
    label {
        font-size: 0.875rem !important;
    }
    
    /* Inputs volle Breite */
    .input-main,
    input[type="text"],
    input[type="number"],
    select,
    textarea {
        width: 100% !important;
        box-sizing: border-box !important;
        font-size: 16px !important; /* Verhindert Auto-Zoom auf iOS */
    }
    
    /* Main Content Padding */
    main {
        padding: 0.5rem !important;
        width: 100%;
        box-sizing: border-box;
        overflow-x: hidden;
    }
    
    .glass {
        padding: 1rem !important;
        width: 95% !important;
        box-sizing: border-box;
    }
    
    .catalog-card {
        padding: 1rem !important;
        width: 100%;
        box-sizing: border-box;
    }
    
    /* Alle Container sollen nicht überlaufen */
    div, section, form {
        max-width: 100%;
        box-sizing: border-box;
    }
}

@media (max-width: 480px) {
    /* Noch kleinere Anpassungen für sehr kleine Bildschirme */
    .header {
        font-size: 1rem;
        padding: 0.75rem;
    }
    
    .nav-btn {
        font-size: 0.75rem;
        padding: 0.5rem 0.75rem;
        flex: 1 1 auto;
        min-width: 0;
        box-sizing: border-box;
    }
    
    .catalog-title {
        font-size: 1.25rem !important;
    }
    
    .glass {
        width: 98% !important;
        padding: 0.75rem !important;
        margin: 0.5rem auto !important;
    }
    
    .admin-grid-form {
        padding: 0.5rem;
        gap: 0.75rem;
    }
    
    /* Buttons volle Breite auf sehr kleinen Bildschirmen */
    .btn-main,
    .btn-secondary,
    .btn-danger {
        width: 100%;
        padding: 0.75rem 1rem !important;
        font-size: 0.875rem !important;
    }
    
    /* Grid-Layouts mit minmax auf mobil zu flex-column */
    div[style*="grid-template-columns"] {
        display: flex !important;
        flex-direction: column !important;
    }
    
    /* Flex-Layouts mit justify-content: space-between auf mobil stapeln */
    div[style*="justify-content: space-between"] {
        flex-direction: column !important;
        gap: 1rem !important;
        align-items: stretch !important;
    }
}

/* Zusätzliche Mobile-Fixes für alle Seiten */
@media (max-width: 768px) {
    /* Header mit Buttons responsive */
    .header {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        align-items: center;
    }
    
    .header button {
        margin: 0 !important;
    }
    
    .header span {
        text-align: center;
        font-size: 1.1rem;
    }
    
    /* Alle flexbox container mit space-between */
    [style*="justify-content: space-between"] {
        flex-wrap: wrap;
        gap: 1rem;
    }
    
    /* Katalog-Cards responsive */
    .catalog-card {
        width: 100%;
        box-sizing: border-box;
        overflow-x: hidden;
    }
    
    /* Question-Container */
    .question-card {
        width: 100%;
        box-sizing: border-box;
    }
    
    /* Alle inline grid-layouts */
    [style*="display: grid"] {
        display: flex !important;
        flex-direction: column !important;
        gap: 1rem !important;
    }
}
