/* Fox Studios Red Theme */
/*
Need to check how ot make the drop down menus background color not white
*/

:root {
    --primary-color: #22c55e;
    --dark-color: #16a34a;
    --light-color: #4ade80;
    --background-dark: #0a0a0a;
    --background-secondary: #1a1a1a;
    --text-primary: #ffffff;
    --text-secondary: #b0b0b0;
    --card-background: rgba(255, 255, 255, 0.05);
    --border-color: rgba(255, 255, 255, 0.1);
    --shadow-color: rgba(34, 197, 94, 0.2);
    --gradient-rainbow: linear-gradient(45deg, #ff6b6b, #4ecdc4, #45b7d1, #96ceb4, #feca57, #ff9ff3, #54a0ff, #5f27cd);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--background-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* Background Animation */
.background-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    opacity: 0.03;
    background: var(--gradient-rainbow);
    background-size: 400% 400%;
    animation: gradientShift 20s ease infinite;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Header */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(10, 10, 10, 0.9);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    z-index: 1000;
    padding: 1rem 0;
    transition: all 0.3s ease;
}

.nav {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    gap: 2rem;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 25px;
    transition: all 0.3s ease;
}

.nav-link:hover {
    color: var(--primary-color);
    background: var(--card-background);
    transform: translateY(-2px);
}

/* Main Container */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 6rem 2rem 2rem;
}

/* Hero Section */
.hero {
    text-align: center;
    margin-bottom: 3rem;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: radial-gradient(circle, var(--primary-color) 0%, transparent 70%);
    opacity: 0.1;
    filter: blur(100px);
    animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); }
    50% { transform: translate(-50%, -50%) scale(1.2); }
}

.hero-title {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--text-primary), var(--primary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
    z-index: 1;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: 2rem;
    position: relative;
    z-index: 1;
}

/* Main Grid */
.main-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
    align-items: start;
}

/* Form Section */
.form-section {
    background: var(--card-background);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 2rem;
    backdrop-filter: blur(20px);
    position: relative;
    overflow: hidden;
}

.form-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--gradient-rainbow);
    background-size: 400% 400%;
    animation: gradientShift 10s ease infinite;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.section-icon {
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: white;
}

.section-title {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* Form Elements */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group.full-width {
    grid-column: 1 / -1;
}

label {
    color: var(--text-secondary);
    font-weight: 500;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
}

input, select, textarea {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 0.75rem 1rem;
    color: var(--text-primary);
    font-size: 0.95rem;
    transition: all 0.3s ease;
}

input:focus, select:focus, textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--shadow-color);
    background: rgba(255, 255, 255, 0.08);
}

textarea {
    resize: vertical;
    min-height: 100px;
}

/* Damage Input */
.damage-input {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.damage-input input {
    flex: 1;
}

.damage-input select {
    min-width: 120px;
}

/* Qualities Section */
.qualities-section {
    margin-top: 2rem;
}

.qualities-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
    min-height: 60px;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.2);
    border: 1px dashed var(--border-color);
    border-radius: 10px;
}

.quality-chip {
    background: var(--primary-color);
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    font-weight: 500;
    animation: slideIn 0.3s ease;
}

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

.quality-chip button {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 0.8rem;
    padding: 0;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.quality-chip button:hover {
    opacity: 1;
}

.quality-input {
    display: flex;
    gap: 0.5rem;
}

.quality-input select {
    flex: 1;
}

.quality-input input {
    width: 80px;
}

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 10px;
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

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

.btn-primary::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.5s ease;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px var(--shadow-color);
}

.btn-secondary {
    background: transparent;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.btn-secondary:hover {
    background: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

.action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-top: 2rem;
}

/* Preview Section */
.preview-section {
    position: sticky;
    top: 6rem;
}

.item-preview {
    background: var(--card-background);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 2rem;
    backdrop-filter: blur(20px);
    border-left: 4px solid var(--primary-color);
    margin-bottom: 2rem;
}

.preview-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 1.5rem;
}

.preview-name {
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--primary-color);
}

.preview-grade {
    font-weight: 500;
    font-size: 0.9rem;
    padding: 0.25rem 0.75rem;
    border-radius: 15px;
}

.grade-common {
    background: rgba(156, 163, 175, 0.2);
    color: #9CA3AF;
}
.grade-rare {
    background: rgba(96, 165, 250, 0.2);
    color: #60A5FA;
}
.grade-epic {
    background: rgba(139, 92, 246, 0.2);
    color: #8B5CF6;
}
.grade-legendary {
    background: rgba(245, 158, 11, 0.2);
    color: #F59E0B;
}

.preview-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.stat-item {
    display: flex;
    flex-direction: column;
}

.stat-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
}

.stat-value {
    font-weight: 600;
    color: var(--text-primary);
}

.preview-section-title {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
    margin-top: 1.5rem;
}

.preview-content {
    color: var(--text-primary);
    line-height: 1.5;
}

/* Saved Weapons */
.saved-item {
    background: var(--card-background);
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 2rem;
    backdrop-filter: blur(20px);
}

.saved-weapon-item {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 0.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.saved-weapon-item:hover {
    background: rgba(255, 255, 255, 0.06);
    transform: translateX(5px);
}

.weapon-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.weapon-name {
    font-weight: 600;
    color: var(--text-primary);
}

.weapon-meta {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.weapon-actions {
    display: flex;
    gap: 0.5rem;
}

.weapon-actions button {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.25rem;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.weapon-actions button:hover {
    color: var(--primary-color);
    background: rgba(239, 68, 68, 0.1);
}

/* Dice Icons */
.dice-icon {
    width: 20px;
    height: 20px;
    display: inline-block;
    margin-right: 2px;
    font-weight: bold;
    text-align: center;
    border-radius: 3px;
    line-height: 20px;
}

.ability {
    background: #10B981;
    color: white;
}
.proficiency {
    background: #F59E0B;
    color: white;
}

/* Responsive */
@media (max-width: 1024px) {
    .main-grid {
        grid-template-columns: 1fr;
    }

    .preview-section {
        position: static;
    }

    .form-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 6rem 1rem 2rem;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .form-section,
    .item-preview,
    .saved-item {
        padding: 1.5rem;
    }

    .action-buttons {
        flex-direction: column;
    }

    .nav-links {
        gap: 1rem;
    }
}

/* Print Styles */
@media print {
    body * {
        visibility: hidden;
    }
    .item-preview, .item-preview * {
        visibility: visible;
    }
    .item-preview {
        position: absolute;
        left: 0;
        top: 0;
        width: 100%;
        border: none;
        background: white;
        color: black;
    }
}