/* =========================================
   SHRIMP STUDIO - MAIN STYLESHEET
   Theme: Deep Sea / High-Tech / Cinematic
   ========================================= */

/* --- RESET & VARIABLES --- */
:root {
    --bg-color: #050505;
    --text-color: #ffffff;
    --accent-color: #FF7F50; /* Shrimp Coral */
    --accent-glow: rgba(255, 127, 80, 0.3);
    --glass-bg: rgba(255, 255, 255, 0.03);
    --glass-border: rgba(255, 255, 255, 0.1);
    --input-bg: rgba(0, 0, 0, 0.5);
    --font-main: 'Outfit', sans-serif;
    
    /* Status Colors */
    --status-todo-bg: #333333; 
    --status-todo-text: #aaaaaa;
    --status-progress-bg: rgba(60, 100, 255, 0.2);
    --status-progress-text: #88aaff;
    --status-blocked-bg: rgba(255, 50, 50, 0.2);
    --status-blocked-text: #ff8888;
    --status-done-bg: rgba(50, 255, 100, 0.2);
    --status-done-text: #88ffaa;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-color);
    color: var(--text-color);
    font-family: var(--font-main);
    min-height: 100vh;
    width: 100vw;
    overflow-x: hidden;
    position: relative;
    /* Flex is default for landing, but dashboard overrides this */
    display: flex;
    flex-direction: column; 
}

/* --- ANIMATED BACKGROUND --- */
.background-noise {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyMDAiIGhlaWdodD0iMjAwIj48ZmlsdGVyIGlkPSJmIj48ZmVUdXJidWxlbmNlIHR5cGU9ImZyYWN0YWxOb2lzZSIgYmFzZUZyZXF1ZW5jeT0iMC42NSIgbnVtT2N0YXZlcz0iMyIgc3RpdGNoVGlsZXM9InN0aXRjaCIvPjwvZmlsdGVyPjxyZWN0IHdpZHRoPSIxMDAlIiBoZWlnaHQ9IjEwMCUiIGZpbHRlcj0idXJsKCNmKSIgb3BhY2l0eT0iMC4wNSIvPjwvc3ZnPg==');
    z-index: -1;
    opacity: 0.4;
    pointer-events: none;
}

.gradient-orb {
    position: fixed;
    border-radius: 50%;
    filter: blur(100px);
    z-index: -2;
    animation: float 20s infinite ease-in-out;
    pointer-events: none;
}

.orb-1 {
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, var(--accent-glow), transparent);
    top: -100px;
    left: -100px;
}

.orb-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(60, 100, 255, 0.15), transparent);
    bottom: -100px;
    right: -100px;
    animation-delay: -5s;
}

@keyframes float {
    0%, 100% { transform: translate(0, 0); }
    50% { transform: translate(50px, 50px); }
}

/* =========================================
   LANDING PAGE STYLES
   ========================================= */

/* Centering wrapper for the Landing Page only */
body:not(:has(.dashboard-nav)) {
    justify-content: center;
    align-items: center;
}

.container {
    text-align: center;
    z-index: 10;
    max-width: 800px;
    padding: 2rem;
    margin: auto;
}

.hero .status-pill {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 8px 16px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 50px;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin-bottom: 2rem;
    backdrop-filter: blur(10px);
}

.dot {
    width: 8px;
    height: 8px;
    background-color: var(--accent-color);
    border-radius: 50%;
    box-shadow: 0 0 10px var(--accent-color);
    animation: pulse 2s infinite;
}

h1 {
    font-size: 5rem;
    font-weight: 900;
    line-height: 1;
    letter-spacing: -2px;
    margin-bottom: 1.5rem;
    background: linear-gradient(135deg, #fff 0%, #aaa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.subtitle {
    font-size: 1.2rem;
    font-weight: 300;
    color: #cccccc;
    line-height: 1.6;
    margin-bottom: 3rem;
}

/* CTA Button */
.cta-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    text-decoration: none;
    color: var(--bg-color);
    background: var(--text-color);
    padding: 16px 32px;
    border: none;
    border-radius: 4px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    cursor: pointer;
    font-family: var(--font-main);
}

.cta-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.4);
    padding-right: 42px;
}

.cta-button svg {
    transition: transform 0.3s ease;
}

.cta-button:hover svg {
    transform: translateX(5px);
}

footer {
    margin-top: 4rem;
    font-size: 0.8rem;
    color: #666;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.4; }
    100% { opacity: 1; }
}

/* =========================================
   DASHBOARD / WEBAPP STYLES
   ========================================= */

.dashboard-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    background: rgba(5, 5, 5, 0.8); /* Slightly darker for readability */
    border-bottom: 1px solid var(--glass-border);
    backdrop-filter: blur(15px);
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 100;
}

.dashboard-container {
    padding-top: 100px; /* Space for fixed header */
    width: 100%;
    max-width: 1400px;
    margin: 0 auto;
    padding-left: 20px;
    padding-right: 20px;
    padding-bottom: 50px;
    flex: 1;
}

/* Login Form Styles */
.login-box {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    padding: 3rem;
    border-radius: 12px;
    backdrop-filter: blur(20px);
    width: 100%;
    max-width: 400px;
    text-align: left;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.75rem;
    color: var(--accent-color);
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 700;
}

input, select, textarea {
    width: 100%;
    background: var(--input-bg);
    border: 1px solid #333;
    color: #fff;
    padding: 12px;
    border-radius: 4px;
    font-family: var(--font-main);
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 15px var(--accent-glow);
}

/* Admin Panel */
.admin-panel {
    background: linear-gradient(90deg, rgba(255, 127, 80, 0.05) 0%, transparent 100%);
    border: 1px solid var(--accent-color);
    border-left: 4px solid var(--accent-color);
    padding: 25px;
    margin-bottom: 40px;
    border-radius: 8px;
}

/* Task Grid Layout */
.task-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 25px;
}

/* Task Cards */
.task-card {
    background: rgba(20, 20, 25, 0.7);
    border: 1px solid var(--glass-border);
    padding: 20px;
    border-radius: 8px;
    position: relative;
    transition: transform 0.2s, border-color 0.2s;
    backdrop-filter: blur(5px);
    display: flex;
    flex-direction: column;
}

.task-card:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 255, 255, 0.3);
    background: rgba(30, 30, 35, 0.9);
}

.task-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 15px;
    align-items: center;
}

/* Status Badges */
.status-badge {
    padding: 6px 10px;
    border-radius: 4px;
    font-size: 0.7rem;
    text-transform: uppercase;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.status-todo { 
    background: var(--status-todo-bg); 
    color: var(--status-todo-text); 
}
.status-inprogress { 
    background: var(--status-progress-bg); 
    color: var(--status-progress-text); 
    border: 1px solid rgba(60, 100, 255, 0.4); 
}
.status-blocked { 
    background: var(--status-blocked-bg); 
    color: var(--status-blocked-text); 
    border: 1px solid rgba(255, 50, 50, 0.4); 
}
.status-done { 
    background: var(--status-done-bg); 
    color: var(--status-done-text); 
    border: 1px solid rgba(50, 255, 100, 0.4); 
}

/* Task Content */
.task-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: #fff;
    line-height: 1.2;
}

.task-meta {
    font-size: 0.8rem;
    color: #888;
    margin-bottom: 15px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 10px;
}

/* Comments Section */
.comments-section {
    margin-top: auto; /* Pushes comments to bottom if card stretches */
    padding-top: 10px;
    font-size: 0.85rem;
}

.comment {
    background: rgba(0, 0, 0, 0.3);
    padding: 8px 10px;
    border-radius: 4px;
    margin-bottom: 8px;
    border-left: 2px solid var(--glass-border);
}

/* =========================================
   RESPONSIVENESS
   ========================================= */
@media (max-width: 768px) {
    /* Landing Mobile */
    h1 { font-size: 3rem; }
    .orb-1, .orb-2 { opacity: 0.5; }
    
    /* Dashboard Mobile */
    .dashboard-nav {
        flex-direction: column;
        gap: 10px;
        text-align: center;
        padding: 1rem;
    }
    
    .dashboard-container {
        padding-top: 140px;
    }
    
    .admin-panel form {
        grid-template-columns: 1fr; /* Stack form inputs on mobile */
    }
}

/* --- AGGIUNTE PER CATEGORIE E FILTRI --- */

/* Filter Bar */
.filter-bar {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    flex-wrap: wrap;
    justify-content: center;
}

.filter-btn {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--glass-border);
    color: #888;
    padding: 8px 16px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 600;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.filter-btn:hover, .filter-btn.active {
    background: var(--accent-color);
    color: #000;
    box-shadow: 0 0 15px var(--accent-glow);
    border-color: var(--accent-color);
}

/* Category Badges on Card */
.category-tag {
    font-size: 0.65rem;
    padding: 2px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 1px;
    border: 1px solid rgba(255,255,255,0.1);
    margin-bottom: 5px;
    display: inline-block;
}

/* Category Specific Colors */
.cat-art { color: #ff9ff3; border-color: rgba(255, 159, 243, 0.3); background: rgba(255, 159, 243, 0.1); }
.cat-engine { color: #54a0ff; border-color: rgba(84, 160, 255, 0.3); background: rgba(84, 160, 255, 0.1); }
.cat-music { color: #feca57; border-color: rgba(254, 202, 87, 0.3); background: rgba(254, 202, 87, 0.1); }
.cat-sfx { color: #ff9f43; border-color: rgba(255, 159, 67, 0.3); background: rgba(255, 159, 67, 0.1); }
.cat-story { color: #1dd1a1; border-color: rgba(29, 209, 161, 0.3); background: rgba(29, 209, 161, 0.1); }
.cat-lore { color: #a29bfe; border-color: rgba(162, 155, 254, 0.3); background: rgba(162, 155, 254, 0.1); }

/* Resources Link Style */
.nav-link-resource {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255,255,255,0.1);
    padding: 8px 16px;
    border-radius: 4px;
    text-decoration: none;
    color: white;
    font-weight: 700;
    border: 1px solid rgba(255,255,255,0.2);
    transition: 0.3s;
}
.nav-link-resource:hover {
    background: white;
    color: black;
}

/* --- STILE PER IL SELETTORE CATEGORIA (ADMIN) --- */
.category-select {
    font-size: 0.65rem;
    padding: 2px 5px;
    border-radius: 4px;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 1px;
    border: 1px solid rgba(255,255,255,0.2);
    margin-bottom: 5px;
    cursor: pointer;
    outline: none;
    /* Rimuove l'aspetto standard del browser */
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none; 
    text-align: center;
    width: auto;
    min-width: 80px;
}

/* Freccetta personalizzata per il selettore categoria */
.category-wrapper {
    position: relative;
    display: inline-block;
}
.category-wrapper::after {
    content: '▼';
    font-size: 0.5rem;
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: none;
    color: inherit;
    opacity: 0.7;
}