:root {
    /* DARK MODE PALETTE */
    --accent: #6366f1; /* Indigo */
    
    --bg: #0f172a;       /* Dark Blue/Black Background */
    --text: #f8fafc;     /* White/Light Gray Text */
    --surface: #1e293b;  /* Dark Gray for Cards */
    
    --radius: 8px;
}

/* Global Reset for better sizing */
*, *::before, *::after {
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    background: var(--bg);
    color: var(--text);
    margin: 0;
    padding: 20px;
    line-height: 1.5; /* Increased line-height for better readability */
}

/* Mobile Layout Wrapper */
#app {
    max-width: 480px;
    margin: 0 auto;
}

header {
    margin-bottom: 2rem;
    text-align: left;
}

h1 { font-size: 1.5rem; margin: 0; }
small { display: block; opacity: 0.7; margin-top: 5px; }

/* FIX: Admin Message Box */
.admin-msg {
    background: rgba(99, 102, 241, 0.15);
    border: 1px solid var(--accent);
    color: #e0e7ff;
    padding: 15px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    font-size: 0.95rem;
    
    /* THESE LINES FIX THE ISSUE: */
    height: auto;               /* Allows box to grow freely */
    min-height: 40px;          /* Minimum size */
    overflow-wrap: break-word;  /* Breaks long URLs so they don't overflow */
    word-wrap: break-word;      /* Backup for older browsers */
    white-space: pre-wrap;      /* Respects your line breaks and spacing */
}

/* Link Cards */
.link-card {
    display: block;
    background: var(--surface);
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: var(--radius);
    text-decoration: none;
    color: inherit;
    border-left: 4px solid var(--accent);
    transition: transform 0.1s;
}

.link-card:active { transform: scale(0.98); }

.link-name {
    display: block;
    font-weight: 700;
    font-size: 1.1rem;
    margin-bottom: 4px;
}

.link-desc {
    font-size: 0.85rem;
    opacity: 0.8;
}
/* Suggestion Box Styles */
.suggestion-box {
    background: var(--surface);
    padding: 15px;
    border-radius: var(--radius);
    margin-bottom: 20px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.suggestion-box h3 {
    margin: 0 0 10px 0;
    font-size: 1rem;
    color: var(--accent);
}

.suggestion-box textarea {
    width: 100%;
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: var(--text);
    padding: 10px;
    border-radius: var(--radius);
    font-family: inherit;
    resize: vertical; /* User can drag to resize height */
    min-height: 80px;
    margin-bottom: 10px;
}

.suggestion-box textarea:focus {
    outline: none;
    border-color: var(--accent);
}

.suggestion-box button {
    background: var(--accent);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: var(--radius);
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    width: 100%; /* Full width for easy mobile tapping */
}

.suggestion-box button:hover {
    opacity: 0.9;
}
/* --- PASTE THIS AT THE BOTTOM OF YOUR EXISTING CSS --- */

/* Navigation Bar */
.nav-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    background: var(--surface);
    padding: 5px;
    border-radius: var(--radius);
}

.nav-btn {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text);
    padding: 10px;
    cursor: pointer;
    border-radius: var(--radius);
    font-weight: 600;
    transition: 0.2s;
    text-align: center;      /* Center text since it's an <a> tag now */
    text-decoration: none;   /* Remove underline from links */
    display: block;          /* Make links fill the space */
}

.nav-btn:hover {
    background: rgba(255, 255, 255, 0.05);
}

.nav-btn.active {
    background: var(--accent);
    color: white;
}

/* Search Bar */
#search-container {
    margin-bottom: 20px;
}

#search-input {
    width: 100%;
    padding: 12px;
    border-radius: var(--radius);
    border: 1px solid #333;
    background: #000000;
    color: var(--text);
    font-size: 1rem;
}

#search-input:focus {
    outline: none;
    border-color: var(--accent);
}

/* Category Headers in File List */
.category-header {
    margin-top: 30px;
    margin-bottom: 10px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent);
    border-bottom: 1px solid #333;
    padding-bottom: 5px;
}
/* --- PASTE THIS AT THE BOTTOM OF YOUR EXISTING CSS --- */

/* Navigation Bar */
.nav-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    background: var(--surface);
    padding: 5px;
    border-radius: var(--radius);
}

.nav-btn {
    flex: 1;
    background: transparent;
    border: none;
    color: var(--text);
    padding: 10px;
    cursor: pointer;
    border-radius: var(--radius);
    font-weight: 600;
    transition: 0.2s;
}

.nav-btn:hover {
    background: rgba(255, 255, 255, 0.05);
}

.nav-btn.active {
    background: var(--accent);
    color: white;
}

/* Search Bar */
#search-container {
    margin-bottom: 20px;
}

#search-input {
    width: 100%;
    padding: 12px;
    border-radius: var(--radius);
    border: 1px solid #333;
    background: #000000;
    color: var(--text);
    font-size: 1rem;
}

#search-input:focus {
    outline: none;
    border-color: var(--accent);
}

/* Category Headers in File List */
.category-header {
    margin-top: 30px;
    margin-bottom: 10px;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--accent);
    border-bottom: 1px solid #333;
    padding-bottom: 5px;
}
/* --- PASTE THIS AT THE BOTTOM OF YOUR CSS --- */

/* Folder Card Style */
.folder-card {
    background: var(--surface);
    padding: 20px;
    border-radius: var(--radius);
    margin-bottom: 15px;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    gap: 15px;
    transition: 0.2s;
}

.folder-card:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateX(5px);
    border-color: var(--accent);
}

.folder-icon {
    font-size: 1.5rem;
}

.folder-name {
    font-weight: 700;
    font-size: 1.1rem;
}

/* Back Button */
.back-btn {
    background: transparent;
    border: none;
    color: var(--accent);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 15px;
    cursor: pointer;
    padding: 0;
}

.back-btn:hover {
    text-decoration: underline;
}
/* Footer Styles */
.site-footer {
    text-align: center;
    margin-top: 4rem;              /* Push it down from content */
    padding: 2rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1); /* Subtle divider */
    color: var(--text);
    opacity: 0.5;                  /* Make it less bright than main text */
    font-size: 0.85rem;
}