@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;800;900&display=swap');

:root {
    --bg-deep: #050505;
    --card-bg: rgba(20, 20, 22, 0.98);
    --card-hover: rgba(25, 25, 28, 0.95);
    --border: #1f1f23;
    
    /* Brand Palette */
    --accent: #a7f3d0;      /* Emerald Accent */
    --accent-red: #aa2222;  /* Brand Red */
    
    /* Typography */
    --text-primary: #ffffff;
    --text-secondary: #e4e4e7; /* High-readability light gray */
    --text-dim: #71717a;
}

/* Base Resets */
* { 
    box-sizing: border-box; 
    margin: 0; 
    padding: 0; 
    -webkit-tap-highlight-color: transparent; 
}

body { 
    background-color: var(--bg-deep); 
    color: var(--text-secondary); 
    font-family: 'Inter', sans-serif; 
    line-height: 1.8;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* Fullscreen Hardware Glow */
.bg-glow-container {
    position: fixed; 
    inset: 0; 
    z-index: -1; 
    pointer-events: none;
    background: radial-gradient(circle at 50% -10%, rgba(167, 243, 208, 0.05), transparent 60%);
}

/* Unified Back Button (Pill Style) */
.back-btn {
    position: fixed; 
    top: 20px; 
    left: 20px; 
    color: var(--text-secondary); 
    text-decoration: none;
    font-size: 0.8rem; 
    font-weight: 800; 
    display: flex; 
    align-items: center; 
    gap: 8px;
    z-index: 1000; 
    background: rgba(15, 15, 17, 0.7); 
    padding: 8px 16px; 
    border-radius: 100px;
    border: 1px solid var(--border); 
    transition: 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.back-btn:hover { 
    color: var(--text-primary); 
    border-color: var(--accent-red); 
    box-shadow: 0 0 15px rgba(170, 34, 34, 0.3); 
    transform: translateY(-1px);
}

/* Unified Language Switcher (Floating Pill) */
.lang-switcher {
    position: fixed; 
    bottom: 30px; 
    left: 50%; 
    transform: translateX(-50%); 
    z-index: 1000;
    background: rgba(15, 15, 17, 0.8); 
    backdrop-filter: blur(20px);
    border: 1px solid var(--border); 
    padding: 4px; 
    border-radius: 100px;
    display: flex; 
    gap: 4px;
    box-shadow: 0 15px 30px rgba(0,0,0,0.8);
}

.lang-btn {
    background: transparent; 
    border: none; 
    color: var(--text-secondary); 
    padding: 8px 22px;
    border-radius: 100px; 
    font-size: 0.75rem; 
    font-weight: 800; 
    cursor: pointer; 
    text-transform: uppercase;
    transition: 0.2s ease;
}

.lang-btn.active { 
    background: var(--text-secondary); 
    color: var(--bg-deep); 
}

/* Content Containers */
main, .container { 
    max-width: 720px; 
    margin: 120px auto 140px; 
    padding: 0 20px; 
}

h1 { 
    font-size: 3.5rem; 
    font-weight: 900; 
    color: var(--text-primary); 
    margin-bottom: 2rem; 
    letter-spacing: -0.04em; 
}

/* Section Headers with Accent Line */
h2 {
    font-size: 0.8rem; 
    text-transform: uppercase; 
    letter-spacing: 0.3em;
    color: var(--accent); 
    margin-top: 2rem; 
    margin-bottom: 1.5rem;
    display: flex; 
    align-items: center; 
    gap: 15px;
}

h2::after { 
    content: ""; 
    height: 1px; 
    background: rgba(167, 243, 208, 0.2); 
    flex-grow: 1; 
}

/* Unified Card Styling (About, Experience, Donate) */
.about-card, .experience-section, .link-item, .device-card {
    background: var(--card-bg); 
    border: 1px solid var(--border);
    border-radius: 16px; 
    padding: 32px; 
    margin-bottom: 32px;
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.about-card:hover, .experience-section:hover, .link-item:hover {
    border-color: rgba(167, 243, 208, 0.3);
    transform: translateY(-2px);
}

/* Typography Details */
strong { color: var(--text-primary); font-weight: 700; }
.dates { font-size: 0.9rem; color: var(--accent); font-weight: 600; margin-bottom: 16px; }

/* Links */
a {
    color: var(--accent); 
    text-decoration: none;
    transition: 0.2s;
}

a:hover { color: var(--text-primary); }

/* Visibility Classes for Language Toggling */
#russian-content, #english-content, .lang-ru, .lang-en { display: none; }