:root {
    --gold: #d4af37;
    --gold-light: #e8c860;
    --gold-dark: #b8942c;
    --deep-blue: #1f3d73;
    --deep-blue-dark: #0f1f3a;
    --midnight: #0a0f1a;
    --earth: #2a1f14;
    --forest: #1a2f1a;
    --parchment: #f4e8d1;
    --parchment-dark: #e5d4b8;
    --text-light: #e8e4dc;
    --text-muted: #9a9590;
}

/* Global reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Spectral', Georgia, serif;
    background: var(--midnight);
    color: var(--text-light);
    min-height: 100vh;
    overflow-x: hidden;
    line-height: 1.7;
}

/* Background texture and atmosphere */
.atmosphere {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
    background:
        radial-gradient(ellipse at 20% 20%, rgba(31, 61, 115, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(42, 31, 20, 0.2) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 100%, rgba(26, 47, 26, 0.15) 0%, transparent 40%);
}

.noise {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
    opacity: 0.03;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* Main content wrapper */
.content {
    position: relative;
    z-index: 2;
}

/* Hero Section */
.hero {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    position: relative;
}

/* Decorative border frame */
.hero::before {
    content: '';
    position: absolute;
    top: 1.5rem;
    left: 1.5rem;
    right: 1.5rem;
    bottom: 1.5rem;
    border: 1px solid rgba(212, 175, 55, 0.2);
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    top: 2rem;
    left: 2rem;
    right: 2rem;
    bottom: 2rem;
    border: 1px solid rgba(212, 175, 55, 0.1);
    pointer-events: none;
}

/* Corner ornaments */
.corner-ornament {
    position: absolute;
    width: 60px;
    height: 60px;
    opacity: 0.4;
}

.corner-ornament::before,
.corner-ornament::after {
    content: '';
    position: absolute;
    background: var(--gold);
}

.corner-ornament.top-left {
    top: 2rem;
    left: 2rem;
}
.corner-ornament.top-left::before {
    width: 30px;
    height: 1px;
    top: 0;
    left: 0;
}
.corner-ornament.top-left::after {
    width: 1px;
    height: 30px;
    top: 0;
    left: 0;
}

.corner-ornament.top-right {
    top: 2rem;
    right: 2rem;
}
.corner-ornament.top-right::before {
    width: 30px;
    height: 1px;
    top: 0;
    right: 0;
}
.corner-ornament.top-right::after {
    width: 1px;
    height: 30px;
    top: 0;
    right: 0;
}

.corner-ornament.bottom-left {
    bottom: 2rem;
    left: 2rem;
}
.corner-ornament.bottom-left::before {
    width: 30px;
    height: 1px;
    bottom: 0;
    left: 0;
}
.corner-ornament.bottom-left::after {
    width: 1px;
    height: 30px;
    bottom: 0;
    left: 0;
}

.corner-ornament.bottom-right {
    bottom: 2rem;
    right: 2rem;
}
.corner-ornament.bottom-right::before {
    width: 30px;
    height: 1px;
    bottom: 0;
    right: 0;
}
.corner-ornament.bottom-right::after {
    width: 1px;
    height: 30px;
    bottom: 0;
    right: 0;
}

/* Logo/Symbol */
.logo-container {
    margin-bottom: 2rem;
    animation: fadeInDown 1.2s ease-out;
}

.logo {
    width: 140px;
    height: 150px;
    filter: drop-shadow(0 0 30px rgba(212, 175, 55, 0.3));
    transition: filter 0.5s ease;
}

.logo:hover {
    filter: drop-shadow(0 0 50px rgba(212, 175, 55, 0.5));
}

/* Title */
.title {
    font-family: 'Uncial Antiqua', 'Cormorant Garamond', serif;
    font-size: clamp(2.5rem, 8vw, 5rem);
    color: var(--gold);
    text-align: center;
    letter-spacing: 0.3em;
    margin-bottom: 0.5rem;
    text-shadow:
        0 0 40px rgba(212, 175, 55, 0.4),
        0 2px 4px rgba(0, 0, 0, 0.5);
    animation: fadeIn 1.5s ease-out 0.3s both;
}

.subtitle {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: clamp(0.9rem, 2vw, 1.1rem);
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5em;
    margin-bottom: 3rem;
    animation: fadeIn 1.5s ease-out 0.6s both;
}

/* Motto Section */
.motto-container {
    max-width: 700px;
    text-align: center;
    animation: fadeIn 1.5s ease-out 0.9s both;
}

.motto {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: clamp(1.1rem, 2.5vw, 1.4rem);
    font-style: italic;
    color: var(--text-light);
    line-height: 2;
    margin-bottom: 2rem;
}

.motto-line {
    display: block;
    opacity: 0;
    animation: fadeInUp 0.8s ease-out forwards;
}

.motto-line:nth-child(1) { animation-delay: 1.2s; }
.motto-line:nth-child(2) { animation-delay: 1.5s; }
.motto-line:nth-child(3) { animation-delay: 1.8s; }

.divider {
    width: 100px;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    margin: 2rem auto;
    opacity: 0;
    animation: fadeIn 1s ease-out 2.1s forwards;
}

.motto-ukrainian {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: clamp(1.3rem, 3vw, 1.8rem);
    font-weight: 600;
    color: var(--gold);
    letter-spacing: 0.15em;
    opacity: 0;
    animation: fadeIn 1s ease-out 2.4s forwards;
}

/* Scroll indicator */
.scroll-indicator {
    position: absolute;
    bottom: 3rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    opacity: 0;
    animation: fadeIn 1s ease-out 3s forwards;
}

.scroll-text {
    font-size: 0.7rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.scroll-arrow {
    width: 20px;
    height: 20px;
    border-right: 1px solid var(--gold);
    border-bottom: 1px solid var(--gold);
    transform: rotate(45deg);
    animation: bounce 2s infinite;
}

/* Main Content Sections */
.section {
    padding: 6rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-title {
    font-family: 'Uncial Antiqua', serif;
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    color: var(--gold);
    letter-spacing: 0.2em;
    margin-bottom: 1rem;
}

.section-subtitle {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1rem;
    color: var(--text-muted);
    font-style: italic;
}

/* About Section */
.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

@media (max-width: 768px) {
    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

.about-text p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    color: var(--text-light);
}

.about-text p:first-of-type::first-letter {
    font-family: 'Uncial Antiqua', serif;
    font-size: 3.5rem;
    float: left;
    line-height: 1;
    padding-right: 0.5rem;
    color: var(--gold);
}

.about-symbol {
    display: flex;
    justify-content: center;
    align-items: center;
}

.about-symbol svg {
    width: 250px;
    height: auto;
    opacity: 0.8;
}

/* Tools Grid */
.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
}

.tool-card {
    background: linear-gradient(135deg, rgba(31, 61, 115, 0.1), rgba(10, 15, 26, 0.8));
    border: 1px solid rgba(212, 175, 55, 0.15);
    padding: 2rem;
    position: relative;
    transition: all 0.4s ease;
    cursor: pointer;
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    display: block;
}

.tool-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.tool-card:hover {
    border-color: rgba(212, 175, 55, 0.4);
    transform: translateY(-5px);
    box-shadow: 0 10px 40px rgba(212, 175, 55, 0.1);
}

.tool-card:hover::before {
    transform: scaleX(1);
}

.tool-icon {
    font-size: 2rem;
    margin-bottom: 1rem;
    display: block;
}

.tool-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.4rem;
    color: var(--gold);
    margin-bottom: 0.5rem;
}

.tool-description {
    font-size: 0.95rem;
    color: var(--text-muted);
    line-height: 1.6;
}

.tool-status {
    display: inline-block;
    margin-top: 1rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 0.25rem 0.75rem;
    border: 1px solid;
}

.tool-status.active {
    color: #4ade80;
    border-color: rgba(74, 222, 128, 0.3);
}

.tool-status.coming {
    color: var(--gold);
    border-color: rgba(212, 175, 55, 0.3);
}

/* Documents / Projects Section */
.documents-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.document-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.5rem 2rem;
    background: rgba(31, 61, 115, 0.05);
    border-left: 2px solid rgba(212, 175, 55, 0.3);
    transition: all 0.3s ease;
    text-decoration: none;
    color: inherit;
}

.document-item:hover {
    background: rgba(31, 61, 115, 0.1);
    border-left-color: var(--gold);
    padding-left: 2.5rem;
}

.document-icon {
    font-size: 1.5rem;
    color: var(--gold);
}

.document-info h4 {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.2rem;
    color: var(--text-light);
    margin-bottom: 0.25rem;
}

.document-info p {
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Footer */
footer {
    text-align: center;
    padding: 4rem 2rem;
    border-top: 1px solid rgba(212, 175, 55, 0.1);
    margin-top: 4rem;
}

.footer-symbol {
    width: 60px;
    height: auto;
    margin-bottom: 1.5rem;
    opacity: 0.5;
}

.footer-text {
    font-size: 0.85rem;
    color: var(--text-muted);
    letter-spacing: 0.1em;
}

.footer-quote {
    font-family: 'Cormorant Garamond', serif;
    font-style: italic;
    font-size: 1rem;
    color: var(--text-muted);
    margin-top: 1rem;
}

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(0) rotate(45deg);
    }
    40% {
        transform: translateY(10px) rotate(45deg);
    }
    60% {
        transform: translateY(5px) rotate(45deg);
    }
}

/* Scroll animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Selection styling */
::selection {
    background: rgba(212, 175, 55, 0.3);
    color: var(--text-light);
}

/* Scrollbar styling */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--midnight);
}

::-webkit-scrollbar-thumb {
    background: rgba(212, 175, 55, 0.3);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(212, 175, 55, 0.5);
}

/* Navigation */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    padding: 1.5rem 3rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 100;
    transition: all 0.3s ease;
}

.nav.scrolled {
    background: rgba(10, 15, 26, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem 3rem;
    border-bottom: 1px solid rgba(212, 175, 55, 0.1);
}

.nav-logo {
    width: 40px;
    height: auto;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.nav.scrolled .nav-logo {
    opacity: 1;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 0.85rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    transition: color 0.3s ease;
}

.nav-links a:hover {
    color: var(--gold);
}

@media (max-width: 600px) {
    .nav {
        padding: 1rem 1.5rem;
    }
    .nav-links {
        gap: 1rem;
    }
    .nav-links a {
        font-size: 0.75rem;
    }
}

@media (max-width: 600px) {
    .nav-links,
    .nav-logo {
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.3s ease;
    }

    .nav.scrolled .nav-links,
    .nav.scrolled .nav-logo {
        opacity: 1;
        pointer-events: auto;
    }
}
