/* Color Palette Variables */
:root {
    --primary-color: #FF937E;
    --secondary-color: #C1E59F;
    --accent-color: #C1E59F;
    --nabbar-bg: #333;
    --dark-hover: #555;
    --bg-dark-1: #282828;
    --bg-dark-2: #353535;
    --light-text: #ffffff;
    --mid-text: #e7e7e7;
    --border-shadow: rgba(0, 0, 0, 0.1);
    --transition-speed: 0.3s ease;
    --size: 80px;     /* square size */
    --offset: 16px;   /* distance from bottom/right */
}

/* Navbar Styling */
.navbar {
    background-color: var(--nabbar-bg);
    padding: 0;
    margin: 0;
    box-shadow: 0 2px 5px var(--border-shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-links {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    gap: 0;
}

.nav-links li {
    margin: 0;
}

.nav-links a {
    display: block;
    padding: 15px 20px;
    color: var(--light-text);
    text-decoration: none;
    font-weight: 500;
    transition: background-color var(--transition-speed), color var(--transition-speed);
}

.nav-links a:hover {
    background-color: var(--dark-hover);
    color: var(--accent-color);
}

/* Header Styling */
header {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--light-text);
    padding: 40px 20px;
    text-align: center;
}

header h1 {
    margin: 0;
    font-size: 2.5em;
}

header p {
    margin: 10px 0 0 0;
    font-size: 1.1em;
    opacity: 0.95;
}

/* Main Content */
main {
    padding: 40px 20px;
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
}

/* Elements List Section */
.elements-list {
    display: grid;
    gap: 30px;
}

.elements-list h2 {
    grid-column: 1 / -1;
    color: var(--light-text);
    margin-top: 0;
}

/* Element Card Styling */
.element-card {
    background: var(--bg-dark-2);
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 8px var(--border-shadow);
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.element-card:hover {
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
    transform: translateY(-2px);
}

.element-header {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 20px;
}

.element-logo {
    width: 80px;
    height: 80px;
    object-fit: contain;
    border-radius: 4px;
    background-color: #f5f5f5;
    padding: 5px;
}

.element-title-section {
    flex: 1;
}

.element-title {
    margin: 0;
    color: var(--primary-color);
    font-size: 1.5em;
}

.element-description {
    color: var(--mid-text);
    line-height: 1.6;
    margin: 15px 0;
}

/* Star Rating */
.element-rating {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 15px 0;
    font-size: 1.1em;
}

.stars {
    color: var(--accent-color);
    font-size: 1.3em;
}

.rating-value {
    color: var(--mid-text);
    font-weight: 500;
}

/* Tags */
.element-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 15px 0;
}

.tag {
    display: inline-block;
    background-color: transparent;
    border: var(--primary-color) 2px solid;
    color: var(--light-text);
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.85em;
    font-weight: 500;
}

/* Related To Section */
.element-related {
    margin-top: 6px;
}

.element-related p {
    margin: 0;
    color: var(--mid-text);
    font-size: 0.95em;
}



/* container fixed to bottom-right */
.gif-floating {
    position: fixed;
    bottom: var(--offset);
    right: var(--offset);
    width: var(--size);
    height: var(--size);
    border-radius: 8px;   /* optional rounded corners */
    overflow: hidden;
    box-shadow: 0 6px 18px rgba(0,0,0,0.25);
    z-index: 9999;
    background: #000;     /* fallback while gif loads */
    display: inline-block;
}

/* the gif itself - keeps aspect, covers square */
.gif-floating img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* cover preserves square filling */
    display: block;
}

/* optional: small hide button in the corner */
.gif-floating .close {
    position: absolute;
    top: 4px;
    right: 4px;
    background: rgba(255,255,255,0.8);
    border: none;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 12px;
    line-height: 20px;
    text-align: center;
    cursor: pointer;
}



/* Footer Styling */
footer {
    background-color: var(--nabbar-bg);
    color: var(--light-text);
    text-align: center;
    padding: 20px;
    margin-top: auto;
}

footer p {
    margin: 0;
}

/* General Styling */
* {
    box-sizing: border-box;
}

html {
    height: 100%;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    background-color: var(--bg-dark-1);
}

main {
    flex: 1;
}
