/* Local Font Definitions */
@font-face {
    font-family: 'Red Hat Display';
    src: url('../assets/fonts/RedHatDisplay-Light.ttf') format('truetype');
    font-weight: 300;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Red Hat Display';
    src: url('../assets/fonts/RedHatDisplay-Regular.ttf') format('truetype');
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Red Hat Display';
    src: url('../assets/fonts/RedHatDisplay-Medium.ttf') format('truetype');
    font-weight: 500;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Red Hat Display';
    src: url('../assets/fonts/RedHatDisplay-SemiBold.ttf') format('truetype');
    font-weight: 600;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Red Hat Display';
    src: url('../assets/fonts/RedHatDisplay-Bold.ttf') format('truetype');
    font-weight: 700;
    font-style: normal;
    font-display: swap;
}

@font-face {
    font-family: 'Red Hat Display';
    src: url('../assets/fonts/RedHatDisplay-ExtraBold.ttf') format('truetype');
    font-weight: 800;
    font-style: normal;
    font-display: swap;
}

/* Theme variables */
:root {
	--primary-color: #7B2429; /* red, match global */
	--secondary-color: #718b5e; /* green accent */
	--accent-color: #A1BBAC;
	--bg-color: #DDE5DB;
	--surface-color: #7FAE6E1a;
	--border-color: #7FAE6E33;
	--text-color: #7B2429; /* red text */
	--border-radius: 1vh;
}

/* Loading Screen */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: var(--bg-color);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 99999;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.loading-screen.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.loading-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3vh;
}

.loader {
    width: 5vw;
    height: 5vw;
    border: 1vh solid rgba(127, 174, 110, 0.2);
    border-top: 1vh solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading-text {
    font-family: 'Red Hat Display', sans-serif;
    font-size: 2vw;
    font-weight: 500;
    color: var(--primary-color);
    text-align: center;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Base page styling */
html {
    background-color: var(--bg-color);
    scrollbar-width: auto;
    scrollbar-color: rgba(0, 0, 0, 0.35) rgba(0, 0, 0, 0.05);
}

html::-webkit-scrollbar { 
    width: 14px; 
    height: 14px; 
}

html::-webkit-scrollbar-track { 
    background: rgba(0, 0, 0, 0.05); 
    border-radius: 50%; 
}

html::-webkit-scrollbar-thumb { 
    background: rgba(0, 0, 0, 0.35); 
    border-radius: 50%; 
}

html::-webkit-scrollbar-thumb:hover { 
    background: rgba(0, 0, 0, 0.5); 
}

body {
    font-family: 'Red Hat Display', sans-serif;
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    margin: 0;
}

/* Main Content */
.main-content {
    padding: 7vh 8vh 3vh 8vh;
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    min-height: 100vh;
    padding-left: 8vh;
    padding-right: 8vh;
}

.page-header {
    text-align: center;
}

.page-title {
    font-size: 5vh;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 1rem;
    letter-spacing: -1px;
}

p {
    font-size: 2.3vh;
    margin-top: 0;
}

/* Content Cards */
.content-card {
    background: #ffffff;
    padding: 5vh;
    border: 0.2vh solid var(--border-color);
    border-radius: var(--border-radius);
    box-shadow: 0 0.7vh 3vh rgba(var(--primary-rgb), 0.1);
}

.card-title {
    font-size: 2.5vh;
    font-weight: 700;
    color: var(--primary-color);
    margin: 0 0 1vh 0;
}

.card-content {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--text-color);
}

.content-list {
    list-style: none;
    padding: 0;
    font-size: 2.3vh;
    padding: 0;
}

.content-list li {
    border-bottom: 0.1vh solid rgba(var(--primary-rgb), 0.3);
    position: relative;
    padding-bottom: 1vh;
    margin-bottom: 1vh;
    padding-left: 3vh;
}

.content-list li:last-child {
    border-bottom: none;
}

.content-list li::before {
    content: '→';
    color: var(--primary-color);
    font-weight: 600;
    font-size: 3vh;
    position: absolute;
    left: 0;
    top: 0.5em;
    line-height: 0;
    margin-right: 0.5vh;
}

/* Bottom page credit */
.site-credit {
    position: static;
    display: block;
    text-align: left;
    color: rgba(0, 0, 0, 0.55);
    padding: 0 2rem 2rem 2rem;
    font-size: 1.5vh;
}

/* Cookie popup */
.cookie-popup {
    position: fixed;
    right: 0.5vw;
    bottom: 0.5vw;
    display: flex;
    align-items: center;
    gap: 0.3vw;
    background: rgba(255, 255, 255, 0.98);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 0.3vw;
    box-shadow: 0 8px 32px rgba(107, 59, 41, 0.15);
    z-index: 9999;
    opacity: 0;
    transform: translateY(100px);
    pointer-events: none;
    transition: opacity 0.25s ease, transform 0.25s ease;
}

.cookie-popup.show {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.cookie-text {
    font-size: 0.8vw;
    color: var(--text-color);
}

.cookie-link {
    color: var(--secondary-color);
    text-decoration: underline;
    font-weight: 600;
}

.cookie-link:hover { 
    color: var(--primary-color); 
}

.cookie-accept {
    background: var(--secondary-color);
    color: #fff;
    border: none;
    border-radius: var(--border-radius);
    padding: 0.3vw;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(127, 174, 110, 0.35);
    transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
    font-family: 'Red Hat Display', sans-serif;
    font-size: 0.8vw;
    outline: none;
}

.cookie-accept:focus {
    background: var(--primary-color);
    box-shadow: 0 4px 16px rgba(127, 174, 110, 0.35), 0 0 0 2px rgba(255, 255, 255, 0.8), 0 0 0 4px rgba(127, 174, 110, 0.4);
}

.cookie-accept:hover {
    background: var(--primary-color);
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(107, 59, 41, 0.25);
}

.cookie-accept:active { 
    transform: translateY(0); 
}
