/* Gitar og Rellion Minecraft Server - Common CSS */

/* Font imports */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&family=Minecraft:wght@500&display=swap');

/* CSS Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* Main colors */
    --primary: #4CAF50;
    --primary-dark: #388E3C; 
    --secondary: #7a5c2d;
    --accent: #ffb74d;
    
    /* Background colors */
    --bg-dark: #1e1e1e;
    --bg-medium: #2c2c2c;
    --bg-light: #3a3a3a;
    --bg-hover: #444444;
    
    /* Text colors */
    --text-light: #f0f0f0;
    --text-muted: #b0b0b0;
    --text-highlight: #ffffff;
    
    /* Border radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    
    /* Shadows */
    --shadow-soft: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 6px 15px rgba(0, 0, 0, 0.3);
    --shadow-hard: 0 8px 30px rgba(0, 0, 0, 0.7);
}

body {
    background-color: var(--bg-dark);
    color: var(--text-light);
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    min-height: 100vh;
    padding: 0;
    margin: 0;
    position: relative;
    z-index: 0;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('https://i.imgur.com/oWEDuaM.jpeg');
    background-size: cover;
    background-repeat: no-repeat;
    background-position: center bottom; /* Show more of the bottom part of the image */
    opacity: 0.85; /* Slightly adjusted opacity */
    z-index: -1;
    pointer-events: none;
}

/* Container for page content */
.page-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.content-container {
    background: var(--bg-medium);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-hard);
    padding: 30px;
    width: 100%;
    max-width: 1000px;
    margin: 20px auto;
    position: relative;
    flex: 1;
    border: 2px solid var(--primary-dark);
}

/* Header Styles */
.site-header {
    background-color: rgba(44, 44, 44, 0.95);
    backdrop-filter: blur(5px);
    border-bottom: 4px solid var(--primary);
    box-shadow: var(--shadow-medium);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    width: 100%;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 20px;
}

.site-title {
    font-family: 'Minecraft', 'Poppins', sans-serif;
    color: var(--text-highlight);
    text-shadow: 2px 2px 0 var(--primary-dark);
    font-size: 2.2rem;
    margin-bottom: 10px;
    text-align: center;
}

.site-subtitle {
    color: var(--text-muted);
    font-size: 1rem;
    margin-bottom: 15px;
    text-align: center;
}

/* Navigation */
.main-nav {
    width: 100%;
}

.nav-list {
    display: flex;
    list-style: none;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.nav-item {
    margin: 5px;
}

.nav-link {
    display: inline-block;
    padding: 8px 16px;
    color: var(--text-light);
    text-decoration: none;
    background-color: var(--bg-light);
    border: 2px solid var(--primary);
    border-radius: var(--radius-md);
    font-weight: 500;
    transition: all 0.3s ease;
    text-align: center;
}

.nav-link:hover, .nav-link.active {
    background-color: var(--primary);
    color: var(--text-highlight);
    transform: translateY(-2px);
    box-shadow: var(--shadow-soft);
}

/* Section Headings */
h1, h2, h3, h4 {
    color: var(--primary);
    margin-bottom: 15px;
}

h1 {
    font-size: 2.4rem;
}

h2 {
    font-size: 1.8rem;
    text-align: center;
    margin-bottom: 25px;
    position: relative;
    padding-bottom: 15px;
}

h2:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background-color: var(--primary);
}

h3 {
    font-size: 1.4rem;
    margin-top: 25px;
}

/* Card Styling */
.card {
    background-color: var(--bg-light);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-medium);
    border-left: 4px solid var(--primary);
}

/* Question and Answer Styling */
.vote-question, .result-question {
    background-color: var(--bg-light);
    border-radius: var(--radius-md);
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: var(--shadow-medium);
    border: 2px solid var(--primary-dark);
    position: relative;
}

.vote-question h3, .result-question h3 {
    margin-top: 0;
    color: var(--text-highlight);
    border-bottom: 2px solid var(--primary-dark);
    padding-bottom: 10px;
    margin-bottom: 15px;
}

.question-description {
    margin-bottom: 15px;
    font-style: italic;
    color: var(--text-muted);
}

.answer {
    background-color: var(--bg-medium);
    border-radius: var(--radius-sm);
    padding: 10px 15px;
    margin-bottom: 8px;
    transition: all 0.2s ease;
}

.answer:hover {
    background-color: var(--bg-hover);
}

.answer label {
    display: flex;
    align-items: center;
    cursor: pointer;
    width: 100%;
}

.answer input[type="radio"] {
    margin-right: 10px;
}

/* Button Styles */
.btn {
    display: inline-block;
    background-color: var(--primary);
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-soft);
}

.btn-secondary {
    background-color: var(--secondary);
}

.btn-secondary:hover {
    background-color: #654b24;
}

/* Form Styling */
.form-group {
    margin-bottom: 20px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

input[type="text"],
input[type="email"],
input[type="password"],
textarea,
select {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--bg-light);
    border-radius: var(--radius-md);
    background-color: var(--bg-hover);
    color: var(--text-light);
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    transition: all 0.3s ease;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(76, 175, 80, 0.3);
}

textarea {
    resize: vertical;
    min-height: 100px;
}

/* Footer */
.site-footer {
    background-color: var(--bg-medium);
    border-top: 4px solid var(--primary);
    text-align: center;
    padding: 20px;
    margin-top: 30px;
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* Status Indicators */
.status-indicator {
    display: inline-flex;
    align-items: center;
    padding: 5px 10px;
    border-radius: 50px;
    font-weight: 500;
    margin: 5px 0;
}

.status-online {
    background-color: rgba(76, 175, 80, 0.2);
    color: #4CAF50;
    border: 1px solid #4CAF50;
}

.status-offline {
    background-color: rgba(244, 67, 54, 0.2);
    color: #f44336;
    border: 1px solid #f44336;
}

/* Responsive design */
@media (max-width: 768px) {
    .content-container {
        padding: 20px;
    }
    
    .site-title {
        font-size: 1.8rem;
    }
    
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.5rem;
    }
    
    .nav-link {
        padding: 8px 12px;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .content-container {
        padding: 15px;
    }
    
    .site-title {
        font-size: 1.5rem;
    }
    
    h1 {
        font-size: 1.8rem;
    }
    
    h2 {
        font-size: 1.3rem;
    }
    
    .nav-list {
        flex-direction: column;
        width: 100%;
    }
    
    .nav-item {
        width: 100%;
        margin: 3px 0;
    }
    
    .nav-link {
        display: block;
        width: 100%;
    }
}

/* Media Queries for Responsive Header */
@media screen and (max-width: 768px) {
    .site-header {
        padding: 8px 0;
    }
    
    .header-container {
        padding: 0 10px;
    }
    
    .site-title {
        font-size: 1.5rem;
        margin-bottom: 5px;
    }
    
    .site-subtitle {
        font-size: 0.8rem;
        margin-bottom: 8px;
    }
    
    .nav-list {
        gap: 5px;
    }
    
    .nav-item {
        margin: 2px;
    }
    
    .nav-link {
        padding: 6px 10px;
        font-size: 0.9rem;
    }
}

@media screen and (max-width: 480px) {
    .site-title {
        font-size: 1.2rem;
    }
    
    .nav-link {
        padding: 5px 8px;
        font-size: 0.8rem;
    }
    
    .nav-list {
        justify-content: center;
    }
}

/* Utility classes */
.text-center {
    text-align: center;
}

/* Feedback Messages */
.feedback-message {
    padding: 15px 20px;
    margin: 15px 0;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    animation: fadeIn 0.5s ease-in-out;
    position: relative;
}

.feedback-success {
    background-color: rgba(76, 175, 80, 0.2);
    border: 1px solid var(--primary);
    color: var(--primary);
}

.feedback-error {
    background-color: rgba(244, 67, 54, 0.2);
    border: 1px solid #f44336;
    color: #f44336;
}

.feedback-info {
    background-color: rgba(33, 150, 243, 0.2);
    border: 1px solid #2196f3;
    color: #2196f3;
}

.feedback-message i {
    margin-right: 10px;
    font-size: 1.2rem;
}

.feedback-message a {
    margin-left: 10px;
    color: inherit;
    text-decoration: underline;
    font-weight: 500;
}

.feedback-message a:hover {
    text-decoration: none;
}

.mt-0 { margin-top: 0; }
.mt-1 { margin-top: 0.5rem; }
.mt-2 { margin-top: 1rem; }
.mt-3 { margin-top: 1.5rem; }

.mb-0 { margin-bottom: 0; }
.mb-1 { margin-bottom: 0.5rem; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }

/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.5s ease-in-out;
}

/* Custom classes for specific components */
.highlight {
    background-color: var(--primary);
    color: white;
    padding: 5px 10px;
    border-radius: var(--radius-sm);
    font-weight: bold;
}

/* Results Page Styling */
.result-question {
    background-color: var(--bg-light);
    border-radius: var(--radius-md);
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-medium);
    border: 2px solid var(--primary);
    position: relative;
}

.total-votes {
    margin-bottom: 20px;
    font-size: 1.1rem;
    color: var(--text-muted);
}

.results-container {
    margin-top: 15px;
}

.result-item {
    margin-bottom: 15px;
    padding: 10px 0;
}

.result-text {
    font-weight: 500;
    margin-bottom: 8px;
}

.result-bar-container {
    background-color: var(--bg-medium);
    border-radius: 50px;
    height: 25px;
    position: relative;
    overflow: hidden;
    border: 1px solid var(--bg-hover);
    display: flex;
    align-items: center;
}

.result-bar {
    background-color: var(--primary);
    height: 100%;
    border-radius: 50px;
    transition: width 1s ease-in-out;
}

.result-stats {
    position: absolute;
    right: 15px;
    color: var(--text-light);
    font-weight: 500;
    font-size: 0.9rem;
    text-shadow: 0 0 3px rgba(0, 0, 0, 0.7);
}

.result-highlight .result-text {
    color: var(--primary);
    font-weight: 700;
}

.result-highlight .result-bar {
    background-color: var(--primary);
    box-shadow: 0 0 10px rgba(76, 175, 80, 0.5);
}

.result-normal .result-bar {
    background-color: var(--secondary);
}

.question-spacer {
    height: 20px;
}

.server-info {
    background-color: var(--bg-light);
    border-radius: var(--radius-md);
    padding: 15px;
    margin: 20px 0;
    text-align: center;
}

.remaining-time {
    color: var(--accent);
    font-weight: 500;
    margin: 10px 0;
}

/* For scrollable areas */
.scrollable {
    max-height: 400px;
    overflow-y: auto;
    padding-right: 5px;
}

.scrollable::-webkit-scrollbar {
    width: 8px;
}

.scrollable::-webkit-scrollbar-track {
    background: var(--bg-medium);
}

.scrollable::-webkit-scrollbar-thumb {
    background-color: var(--primary);
    border-radius: 20px;
}

/* View Results container */
.view-results-container {
    margin-top: 20px;
    text-align: center;
    padding: 15px;
    background-color: rgba(0, 0, 0, 0.05);
    border-radius: 8px;
    border-top: 1px solid #ddd;
}

.view-results-container .btn-secondary {
    background-color: #6c757d;
    color: white;
}

.view-results-container .btn-secondary:hover {
    background-color: #5a6268;
}
