:root {
    --primary: #4ade80; /* Vibrant Green */
    --primary-dark: #16a34a;
    --secondary: #fb923c; /* Vibrant Orange */
    --accent: #f472b6;
    --bg-dark: #0f172a;
    --surface: rgba(30, 41, 59, 0.7);
    --surface-glass: rgba(30, 41, 59, 0.4);
    --text-main: #f8fafc;
    --text-dim: #94a3b8;
    --border: rgba(255, 255, 255, 0.1);
    --font-main: 'Outfit', sans-serif;
}

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

body {
    font-family: var(--font-main);
    background: var(--bg-dark);
    background-image: 
        radial-gradient(at 0% 0%, rgba(74, 222, 128, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(251, 146, 60, 0.15) 0px, transparent 50%);
    color: var(--text-main);
    min-height: 100vh;
    overflow-x: hidden;
}

/* Glassmorphism */
.glass {
    background: var(--surface-glass);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--border);
    border-radius: 24px;
}

/* Layout */
.app-container {
    max-width: 500px;
    margin: 0 auto;
    padding: 20px;
    padding-bottom: 100px;
}

.screen {
    display: none;
    animation: fadeIn 0.4s ease-out;
}

.screen.active {
    display: block;
}

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

/* Components */
.card {
    background: var(--surface);
    padding: 20px;
    border-radius: 24px;
    margin-bottom: 16px;
    border: 1px solid var(--border);
}

.btn {
    width: 100%;
    padding: 16px;
    border-radius: 16px;
    border: none;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #064e3b;
}

.btn-primary:active {
    transform: scale(0.98);
}

/* Navigation */
.nav-bar {
    position: fixed;
    bottom: 20px;
    left: 20px;
    right: 20px;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: 30px;
    display: flex;
    justify-content: space-around;
    padding: 12px;
    z-index: 1000;
}

.nav-item {
    color: var(--text-dim);
    text-decoration: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 10px;
    transition: 0.2s;
}

.nav-item.active {
    color: var(--primary);
}

.nav-item i {
    font-size: 20px;
    margin-bottom: 4px;
}

/* Utility */
.text-gradient {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.status-valid { background: rgba(74, 222, 128, 0.2); color: var(--primary); }
.status-pending { background: rgba(251, 146, 60, 0.2); color: var(--secondary); }

/* Tree View */
.tree-list {
    list-style: none;
}

.tree-node {
    padding: 16px;
    border-left: 2px solid var(--border);
    margin-left: 10px;
    position: relative;
}

.tree-node::before {
    content: '';
    position: absolute;
    left: -2px;
    top: 28px;
    width: 10px;
    height: 1px;
    background: var(--border);
}

/* Dashboard Menu Grid */
.menu-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 20px;
    margin-bottom: 30px;
}

.menu-btn {
    background: linear-gradient(135deg, #1e293b, #0f172a);
    border: 1px solid var(--border);
    border-radius: 40px;
    padding: 18px 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    text-decoration: none;
    transition: all 0.2s;
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    height: 56px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.menu-btn:active {
    transform: scale(0.96);
    background: linear-gradient(135deg, #334155, #1e293b);
}

/* Collapsible */
.collapsible-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease-out;
    opacity: 0;
    pointer-events: none;
}

.collapsible-content.expanded {
    max-height: 2000px;
    opacity: 1;
    pointer-events: auto;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    user-select: none;
    margin: 24px 0 16px;
}

.section-header h3 {
    margin: 0 !important;
}

.section-header .toggle-icon {
    transition: transform 0.3s ease;
    color: var(--text-dim);
    transform: rotate(-180deg);
}

.section-header.expanded .toggle-icon {
    transform: rotate(0deg);
}
