/* =========================
   THEME VARIABLES
========================= */
:root {
    --bg: #ffffff;
    --text: #0f0f0f;
    --muted: #777;
    --border: #e5e5e5;
    --card: #f3f3f3;
}

[data-theme="dark"] {
    --bg: #0f0f0f;
    --text: #ffffff;
    --muted: #aaa;
    --border: #222;
    --card: #181818;
}

/* =========================
   RESET / BASE
========================= */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: 'Inter', sans-serif;
    background: var(--bg);
    color: var(--text);
    transition: background 0.4s ease, color 0.4s ease;
    line-height: 1.6;
}

img {
    max-width: 100%;
    display: block;
}

a {
    color: inherit;
}

/* =========================
   LAYOUT WRAPPER
========================= */
#page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* =========================
   NAVBAR
========================= */
header {
    position: sticky;
    top: 0;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    z-index: 100;
}

.nav {
    max-width: 1200px;
    margin: auto;
    padding: 18px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-weight: 900;
    letter-spacing: 3px;
    text-decoration: none;
    font-size: 18px;
}

nav {
    display: flex;
    align-items: center;
}

nav a {
    text-decoration: none;
    margin-left: 28px;
    font-weight: 500;
    opacity: 0.85;
    transition: opacity 0.3s ease;
}

nav a:hover {
    opacity: 1;
}

#theme-toggle {
    background: none;
    border: none;
    cursor: pointer;
    margin-left: 24px;
    color: var(--text);
}

/* =========================
   BUTTONS
========================= */
.btn {
    padding: 14px 34px;
    text-decoration: none;
    font-weight: 600;
    border: 2px solid var(--text);
    color: var(--text);
    display: inline-block;
    transition: all 0.3s ease;
}

.btn.primary:hover {
    background: var(--text);
    color: var(--bg);
}

.btn.outline {
    opacity: 0.7;
}

.btn.outline:hover {
    opacity: 1;
}

/* =========================
   GLOBAL CONTENT
========================= */
main {
    flex: 1;
}

section {
    padding: 100px 24px;
    max-width: 1100px;
    margin: auto;
    text-align: center;
}

h1, h2, h3 {
    line-height: 1.1;
}

h2 {
    font-size: 36px;
    margin-bottom: 16px;
}

p {
    color: var(--muted);
    font-size: 16px;
}

/* =========================
   FOOTER
========================= */
footer {
    border-top: 1px solid var(--border);
    padding: 60px 24px;
    background: var(--bg);
}

.footer-inner {
    max-width: 1100px;
    margin: auto;
    text-align: center;
}

.footer-inner p {
    font-weight: 600;
    letter-spacing: 2px;
    margin-bottom: 24px;
}

.socials {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
}

.socials a {
    opacity: 0.6;
    transition: opacity 0.3s ease;
}

.socials a:hover {
    opacity: 1;
}

.copyright {
    font-size: 13px;
    opacity: 0.5;
}

/* =========================
   ANIMATIONS
========================= */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: all 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* =========================
   PAGE TRANSITION
========================= */
.page {
    animation: pageFade 0.5s ease;
}

@keyframes pageFade {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* =========================
   RESPONSIVE
========================= */
@media (max-width: 800px) {
    nav a {
        margin-left: 18px;
    }

    section {
        padding: 80px 24px;
    }
}
