/* =========================================
   PromptVault - Main Stylesheet
   Dark Glassmorphism | Space Mono + DM Sans
   ========================================= */

@import url('https://fonts.googleapis.com/css2?family=Space+Mono:wght@400;700&family=DM+Sans:ital,wght@0,300;0,400;0,500;0,700;1,300&display=swap');

/* ---------- CSS Custom Properties ---------- */
:root {
    --bg:           #080e1a;
    --bg-2:         #0f172a;
    --glass:        rgba(15, 23, 42, 0.75);
    --glass-card:   rgba(15, 23, 42, 0.85);
    --glass-border: rgba(255, 255, 255, 0.08);
    --glass-hover:  rgba(255, 255, 255, 0.14);
    --accent:       #3b82f6;
    --accent-glow:  rgba(59, 130, 246, 0.3);
    --accent-dark:  #2563eb;
    --accent-2:     #06b6d4;
    --danger:       #ef4444;
    --danger-glow:  rgba(239, 68, 68, 0.3);
    --success:      #22c55e;
    --success-glow: rgba(34, 197, 94, 0.3);
    --text:         #e2e8f0;
    --text-muted:   #94a3b8;
    --fav:          #ef4444;
    --radius-sm:    0.5rem;
    --radius:       0.85rem;
    --radius-lg:    1.25rem;
    --shadow:       0 8px 32px rgba(0, 0, 0, 0.5);
    --shadow-lg:    0 20px 48px rgba(0, 0, 0, 0.65);
    --transition:   all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ---------- Reset & Accessibility ---------- */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background: var(--bg);
    color: var(--text);
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-image:
        linear-gradient(rgba(59, 130, 246, 0.035) 1px, transparent 1px),
        linear-gradient(90deg, rgba(59, 130, 246, 0.035) 1px, transparent 1px);
    background-size: 40px 40px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Skip link for screen readers */
.skip-link {
    position: absolute;
    top: -60px;
    left: 1rem;
    background: var(--accent);
    color: white;
    padding: 0.75rem 1.25rem;
    border-radius: var(--radius);
    font-weight: 700;
    z-index: 9999;
    text-decoration: none;
    transition: top 0.2s ease;
}

.skip-link:focus {
    top: 1rem;
}

/* ---------- Header & Navigation ---------- */
header {
    background: var(--glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--glass-border);
    padding: 0.9rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    color: var(--text);
    text-decoration: none;
    font-family: 'Space Mono', monospace;
    font-weight: 700;
    font-size: 1.3rem;
    letter-spacing: -0.02em;
    transition: var(--transition);
}

.logo:hover {
    opacity: 0.95;
    transform: translateY(-1px);
}

.logo-icon {
    width: 36px;
    height: 36px;
    background: var(--accent);
    border-radius: 0.5rem;
    display: grid;
    place-items: center;
    font-size: 0.9rem;
    color: white;
    box-shadow: 0 0 16px var(--accent-glow);
}

nav {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.nav-link {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.92rem;
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.75rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

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

/* ---------- Flash Notification Messages ---------- */
.flash-container {
    padding: 1.25rem 5% 0;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.flash {
    padding: 0.85rem 1.25rem;
    border-radius: var(--radius);
    font-size: 0.9rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.65rem;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.flash-success {
    background: rgba(34, 197, 94, 0.12);
    border: 1px solid rgba(34, 197, 94, 0.35);
    color: #4ade80;
}

.flash-error {
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.35);
    color: #f87171;
}

/* ---------- Metrics Banner ---------- */
.metrics-banner {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem 5% 0.5rem;
    flex-wrap: wrap;
}

.metric-pill {
    background: var(--glass);
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
    padding: 0.4rem 1rem;
    border-radius: 999px;
    font-size: 0.82rem;
    color: var(--text-muted);
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.metric-pill strong {
    color: var(--text);
    font-family: 'Space Mono', monospace;
    font-weight: 700;
}

.metric-pill i {
    color: var(--accent);
}

.metric-pill i.text-fav {
    color: var(--fav);
}

/* ---------- Toolbar (Search + Filters + Sort) ---------- */
.toolbar {
    padding: 1.25rem 5% 1.75rem;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

/* Search Box */
.search-form {
    width: 100%;
}

.search-box {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 680px;
    margin: 0 auto;
}

.search-box input {
    width: 100%;
    padding: 0.85rem 3rem 0.85rem 2.85rem;
    background: var(--glass);
    backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: 999px;
    color: var(--text);
    font-size: 0.92rem;
    transition: var(--transition);
}

.search-box input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow), 0 8px 24px rgba(0, 0, 0, 0.4);
    background: rgba(15, 23, 42, 0.95);
}

.search-icon {
    position: absolute;
    left: 1.1rem;
    color: var(--text-muted);
    font-size: 0.95rem;
    pointer-events: none;
}

.search-clear-btn {
    position: absolute;
    right: 1.1rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.08);
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    text-decoration: none;
    font-size: 0.75rem;
    transition: var(--transition);
}

.search-clear-btn:hover {
    color: var(--text);
    background: rgba(255, 255, 255, 0.2);
}

/* Controls Row */
.controls-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.filter-group {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
}

.filter-chip {
    padding: 0.45rem 1.05rem;
    border-radius: 999px;
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    color: var(--text-muted);
    background: var(--glass);
    border: 1px solid var(--glass-border);
    transition: var(--transition);
    letter-spacing: 0.02em;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.filter-chip:hover {
    color: var(--text);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-1px);
}

.filter-chip.active {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
    box-shadow: 0 0 14px var(--accent-glow);
}

.fav-chip.active {
    background: var(--fav);
    border-color: var(--fav);
    box-shadow: 0 0 14px rgba(239, 68, 68, 0.35);
}

.sort-group {
    display: flex;
    gap: 0.4rem;
    align-items: center;
}

.sort-btn {
    padding: 0.45rem 0.95rem;
    border-radius: var(--radius-sm);
    font-size: 0.82rem;
    font-weight: 600;
    text-decoration: none;
    color: var(--text-muted);
    background: var(--glass);
    border: 1px solid var(--glass-border);
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.sort-btn:hover {
    color: var(--text);
    border-color: rgba(255, 255, 255, 0.2);
}

.sort-btn.active {
    color: var(--accent);
    border-color: var(--accent);
    background: rgba(59, 130, 246, 0.1);
}

/* ---------- Gallery Grid ---------- */
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.75rem;
    padding: 0 5% 5rem;
}

/* ---------- Card ---------- */
.card {
    background: var(--glass-card);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: transform 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
    opacity: 0;
    animation: fadeUp 0.5s ease forwards;
    display: flex;
    flex-direction: column;
}

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

.card:hover {
    transform: translateY(-6px);
    border-color: rgba(59, 130, 246, 0.4);
    box-shadow: 0 18px 48px rgba(0, 0, 0, 0.55), 0 0 24px var(--accent-glow);
}

/* Image Box */
.image-box {
    position: relative;
    height: 240px;
    overflow: hidden;
    background: #020617;
}

.image-box img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    display: block;
}

.card:hover .image-box img {
    transform: scale(1.05);
}

/* Overlay Actions */
.card-overlay {
    position: absolute;
    inset: 0;
    background: rgba(8, 14, 26, 0.72);
    backdrop-filter: blur(3px);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.7rem;
    opacity: 0;
    transition: opacity 0.25s ease;
}

.card:hover .card-overlay {
    opacity: 1;
}

.overlay-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    display: grid;
    place-items: center;
    text-decoration: none;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
}

.overlay-btn:hover {
    background: rgba(255, 255, 255, 0.28);
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.overlay-btn.danger:hover {
    background: var(--danger);
    border-color: var(--danger);
}

.overlay-btn.copied {
    background: var(--success) !important;
    border-color: var(--success) !important;
}

/* Favorite Button */
.fav-form {
    position: absolute;
    top: 12px;
    right: 12px;
    z-index: 10;
}

.fav-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.18);
    color: rgba(255, 255, 255, 0.6);
    display: grid;
    place-items: center;
    cursor: pointer;
    font-size: 0.85rem;
    transition: var(--transition);
}

.fav-btn:hover {
    color: var(--fav);
    border-color: var(--fav);
    transform: scale(1.08);
}

.fav-btn.is-fav {
    color: var(--fav);
    border-color: var(--fav);
    background: rgba(239, 68, 68, 0.25);
    box-shadow: 0 0 12px rgba(239, 68, 68, 0.35);
}

/* Card Content */
.card-content {
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    flex-grow: 1;
}

.card-meta-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.category-badge {
    display: inline-block;
    padding: 0.22rem 0.75rem;
    border-radius: 999px;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    background: var(--accent-glow);
    color: var(--accent);
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.btn-text-copy {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 0.78rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    transition: var(--transition);
}

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

.prompt-text {
    font-size: 0.88rem;
    line-height: 1.65;
    color: var(--text);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-style: italic;
    flex-grow: 1;
}

.card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 0.4rem;
    padding-top: 0.6rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.timestamp {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.card-view-link {
    background: transparent;
    border: none;
    color: var(--accent);
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    transition: var(--transition);
}

.card-view-link:hover {
    color: var(--text);
    transform: translateX(2px);
}

/* ---------- Details Modal ---------- */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(3, 7, 18, 0.85);
    backdrop-filter: blur(10px);
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s ease, visibility 0.25s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-card {
    background: var(--glass-card);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    max-width: 880px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: zoomUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes zoomUp {
    from { opacity: 0; transform: scale(0.94); }
    to   { opacity: 1; transform: scale(1); }
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--glass-border);
    color: var(--text);
    cursor: pointer;
    display: grid;
    place-items: center;
    font-size: 1rem;
    transition: var(--transition);
    z-index: 10;
}

.modal-close:hover {
    background: var(--danger);
    color: white;
}

.modal-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.modal-image-col {
    background: #020617;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.modal-image-col img {
    width: 100%;
    height: 100%;
    max-height: 480px;
    object-fit: contain;
}

.modal-info-col {
    padding: 2.25rem 2rem 2rem 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.modal-heading {
    font-family: 'Space Mono', monospace;
    font-size: 1.25rem;
    color: var(--text);
}

.modal-prompt-box {
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius);
    padding: 1.1rem;
    font-size: 0.92rem;
    line-height: 1.7;
    color: var(--text);
    max-height: 220px;
    overflow-y: auto;
    font-style: italic;
}

.modal-details-meta {
    display: flex;
    gap: 1.25rem;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.modal-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: auto;
    padding-top: 1rem;
}

/* ---------- Toast Notification ---------- */
.toast-notification {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--accent);
    color: white;
    padding: 0.8rem 1.4rem;
    border-radius: var(--radius);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), 0 0 20px var(--accent-glow);
    font-weight: 600;
    font-size: 0.9rem;
    z-index: 3000;
    transform: translateY(100px);
    opacity: 0;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.3s ease;
    pointer-events: none;
}

.toast-notification.visible {
    transform: translateY(0);
    opacity: 1;
}

/* ---------- Empty State ---------- */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 5rem 1.5rem;
    text-align: center;
    animation: fadeUp 0.5s ease forwards;
}

.empty-icon {
    font-size: 3.5rem;
    color: var(--text-muted);
    opacity: 0.4;
}

.empty-state h2 {
    font-family: 'Space Mono', monospace;
    font-size: 1.4rem;
    color: var(--text);
}

.empty-state p {
    color: var(--text-muted);
    font-size: 0.95rem;
    max-width: 420px;
    line-height: 1.6;
}

.empty-state-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 0.5rem;
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.65rem 1.35rem;
    border-radius: var(--radius-sm);
    font-size: 0.88rem;
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    transition: var(--transition);
    font-family: 'DM Sans', sans-serif;
}

.btn-primary {
    background: var(--accent);
    color: white;
    box-shadow: 0 0 16px var(--accent-glow);
}

.btn-primary:hover {
    background: var(--accent-dark);
    box-shadow: 0 0 24px rgba(59, 130, 246, 0.5);
    transform: translateY(-1px);
}

.btn-ghost {
    background: var(--glass);
    color: var(--text-muted);
    border: 1px solid var(--glass-border);
}

.btn-ghost:hover {
    color: var(--text);
    border-color: rgba(255, 255, 255, 0.25);
    background: rgba(255, 255, 255, 0.05);
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-danger:hover {
    background: #dc2626;
    box-shadow: 0 0 20px var(--danger-glow);
}

/* ---------- Form Pages ---------- */
.form-page {
    display: flex;
    justify-content: center;
    padding: 2.5rem 1.5rem 5rem;
}

.form-card {
    width: 100%;
    max-width: 620px;
    background: var(--glass-card);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    animation: fadeUp 0.4s ease forwards;
    box-shadow: var(--shadow);
}

.form-header {
    text-align: center;
    margin-bottom: 2rem;
}

.form-icon {
    width: 56px;
    height: 56px;
    border-radius: 1rem;
    background: var(--accent);
    display: grid;
    place-items: center;
    font-size: 1.4rem;
    color: white;
    margin: 0 auto 1rem;
    box-shadow: 0 0 24px var(--accent-glow);
}

.form-header h2 {
    font-family: 'Space Mono', monospace;
    font-size: 1.5rem;
    margin-bottom: 0.4rem;
}

.form-header p {
    color: var(--text-muted);
    font-size: 0.92rem;
}

.input-group {
    margin-bottom: 1.5rem;
}

.label-with-counter {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.input-group label {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.char-counter {
    font-size: 0.78rem;
    color: var(--text-muted);
    font-family: 'Space Mono', monospace;
}

input[type="text"],
input[type="file"],
textarea {
    width: 100%;
    padding: 0.85rem 1rem;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid var(--glass-border);
    border-radius: 0.75rem;
    color: var(--text);
    font-family: 'DM Sans', sans-serif;
    font-size: 0.95rem;
    transition: var(--transition);
    resize: vertical;
}

input[type="text"]:focus,
textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

input::placeholder, textarea::placeholder {
    color: rgba(148, 163, 184, 0.6);
}

/* File Drop Area */
.file-drop-area {
    position: relative;
    border: 2px dashed var(--glass-border);
    border-radius: 0.75rem;
    padding: 1.75rem 1.25rem;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    background: rgba(0, 0, 0, 0.25);
}

.file-drop-area:hover, .file-drop-area.dragover {
    border-color: var(--accent);
    background: rgba(59, 130, 246, 0.08);
}

.file-drop-area input[type="file"] {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
    width: 100%;
    height: 100%;
    padding: 0;
    border: none;
}

.file-drop-label {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    color: var(--text-muted);
    font-size: 0.9rem;
    pointer-events: none;
}

.file-drop-label i {
    font-size: 2rem;
    margin-bottom: 0.3rem;
    color: var(--accent);
}

.file-drop-label small {
    font-size: 0.75rem;
    opacity: 0.75;
}

#preview {
    width: 100%;
    max-height: 220px;
    object-fit: cover;
    border-radius: 0.5rem;
    margin-top: 1rem;
    border: 1px solid var(--glass-border);
}

/* Tag Suggestions */
.suggested-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    align-items: center;
    margin-top: 0.6rem;
}

.tags-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-right: 0.2rem;
}

.tag-pill {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    border-radius: 999px;
    padding: 0.2rem 0.6rem;
    font-size: 0.75rem;
    cursor: pointer;
    transition: var(--transition);
}

.tag-pill:hover {
    background: var(--accent-glow);
    color: var(--text);
    border-color: var(--accent);
}

/* Form Actions */
.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1rem;
}

/* Edit Preview */
.edit-preview {
    border-radius: 0.75rem;
    overflow: hidden;
    margin-bottom: 2rem;
    max-height: 240px;
    border: 1px solid var(--glass-border);
    background: #020617;
}

.edit-preview img {
    width: 100%;
    height: 240px;
    object-fit: contain;
    display: block;
}

/* ---------- About Page & Specifications ---------- */
.about-card {
    max-width: 760px;
}

.about-body {
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
    color: var(--text-muted);
    line-height: 1.75;
}

.about-section h3 {
    font-family: 'Space Mono', monospace;
    font-size: 1.05rem;
    color: var(--text);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.about-section h3 i {
    color: var(--accent);
}

.about-section p {
    margin-bottom: 0.75rem;
}

.about-section strong {
    color: var(--text);
}

.about-features {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    background: rgba(59, 130, 246, 0.06);
    border: 1px solid rgba(59, 130, 246, 0.16);
    border-radius: 0.6rem;
    padding: 0.75rem 1rem;
    font-size: 0.88rem;
    color: var(--text);
}

.feature-item i {
    color: var(--accent);
    font-size: 1rem;
}

.specs-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
    padding-left: 0.25rem;
}

.specs-list li {
    font-size: 0.88rem;
    line-height: 1.6;
    position: relative;
    padding-left: 1.25rem;
}

.specs-list li::before {
    content: "-";
    position: absolute;
    left: 0;
    color: var(--accent);
    font-weight: bold;
}

.tech-stack {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.tech-badge {
    padding: 0.35rem 0.85rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 600;
    background: var(--glass);
    border: 1px solid var(--glass-border);
    color: var(--text-muted);
    font-family: 'Space Mono', monospace;
}

.academic-note-box {
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(59, 130, 246, 0.25);
    border-radius: var(--radius);
    padding: 1.25rem;
    margin-top: 0.5rem;
}

.academic-text {
    font-style: italic;
    font-size: 0.88rem;
    border-left: 3px solid var(--accent);
    padding-left: 0.85rem;
    margin-top: 0.5rem;
}

/* ---------- Error Pages ---------- */
.error-card {
    text-align: center;
    max-width: 520px;
}

.error-icon {
    background: rgba(239, 68, 68, 0.15);
    color: var(--danger);
    box-shadow: 0 0 24px rgba(239, 68, 68, 0.3);
}

.error-actions {
    display: flex;
    justify-content: center;
    margin-top: 1.5rem;
}

/* ---------- Footer ---------- */
footer {
    text-align: center;
    padding: 2.5rem 5%;
    color: var(--text-muted);
    font-size: 0.82rem;
    border-top: 1px solid var(--glass-border);
    margin-top: auto;
    background: rgba(15, 23, 42, 0.4);
}

.footer-subtitle {
    margin-top: 0.35rem;
    font-size: 0.75rem;
    opacity: 0.6;
}

/* ---------- Responsive Layout ---------- */
@media (max-width: 768px) {
    header { padding: 0.85rem 4%; }
    .logo { font-size: 1.15rem; }
    nav { gap: 0.75rem; }
    .nav-link { display: none; }
    .toolbar { padding: 1rem 4%; }
    .gallery { padding: 0 4% 3rem; gap: 1.2rem; }
    .form-card { padding: 1.75rem 1.25rem; }
    .about-features { grid-template-columns: 1fr; }
    .form-actions { flex-direction: column; }
    .form-actions .btn { width: 100%; justify-content: center; }
    .modal-grid { grid-template-columns: 1fr; }
    .modal-info-col { padding: 1.5rem; }
    .modal-image-col { max-height: 300px; }
}
