/* /htdocs/test/css/style.css */

/* --- General --- */
body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    margin: 0;
    background-color: #1a202c; /* Dark background */
    color: #e2e8f0; /* Light text */
    line-height: 1.6;
}

a {
    color: #48bb78; /* Green links */
    text-decoration: none;
    transition: color 0.2s ease-in-out;
}

a:hover {
    color: #9ae6b4; /* Lighter green on hover */
}

h1, h2, h3, h4, h5, h6 {
    color: #9ae6b4; /* Green headers */
    margin-bottom: 0.8em;
}

hr {
    border: none;
    border-top: 1px solid #4a5568; /* Darker gray border */
    margin: 2rem 0;
}

/* --- Public Site Layout --- */
.public-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.public-header {
    background-color: #2d3748; /* Slightly lighter dark */
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #48bb78;
}

.public-header .logo {
    font-size: 1.8rem;
    font-weight: bold;
    color: #9ae6b4;
}

.public-header nav a {
    color: #e2e8f0;
    margin-left: 1.5rem;
    padding: 0.5rem 1rem;
    border-radius: 4px;
}
.public-header nav a:hover {
    background-color: #4a5568;
    color: #ffffff;
}
.public-header .admin-link {
    background-color: #48bb78;
    color: #1a202c;
    font-weight: bold;
}
.public-header .admin-link:hover {
     background-color: #9ae6b4;
}


.public-footer {
    background-color: #2d3748;
    color: #a0aec0; /* Medium gray text */
    text-align: center;
    padding: 1.5rem;
    margin-top: 3rem;
    border-top: 1px solid #4a5568;
}

/* --- Game Cards (Homepage, etc.) --- */
.game-card {
    background-color: #2d3748;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    display: block; /* Make the whole card clickable */
    color: #e2e8f0; /* Ensure text inside link is light */
}
.game-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.3);
}
.game-card img {
    width: 100%;
    height: 16rem; /* Fixed height for consistency */
    object-fit: cover; /* Cover ensures image fills space */
    border-bottom: 1px solid #4a5568;
}
.game-card .p-4 { /* Tailwind class override */
    padding: 1rem;
}
.game-card h3 {
    color: #9ae6b4;
    margin-bottom: 0.5rem;
}
.game-card p {
    color: #a0aec0;
}

/* --- Game Page Specific --- */
.game-details-box {
    background-color: #2d3748; /* Darker box for details */
    padding: 1rem;
    border-radius: 8px;
}
.game-details-box h3 { color: #9ae6b4; }
.game-details-box p { color: #cbd5e0; }
.game-details-box strong { color: #e2e8f0; }

.info-tag { /* Platform/Genre Tags */
    background-color: #4a5568;
    color: #e2e8f0;
}
.info-tag:hover { background-color: #718096; } /* Slightly lighter hover */


/* --- Admin Panel --- */
.admin-layout { display: flex; min-height: 100vh; }
.sidebar { width: 220px; background-color: #1a202c; color: #cbd5e0; padding: 20px; border-right: 1px solid #4a5568; }
.sidebar h2 { margin: 0 0 20px 0; text-align: center; color: #9ae6b4; }
.sidebar ul { list-style-type: none; padding: 0; margin: 0; }
.sidebar ul li a { display: block; color: #cbd5e0; text-decoration: none; padding: 10px 15px; border-radius: 4px; margin-bottom: 5px; transition: background-color 0.2s; }
.sidebar ul li a:hover, .sidebar ul li a.active { background-color: #2d3748; color: #ffffff; }
.sidebar .logout { margin-top: 30px; padding-top: 15px; border-top: 1px solid #4a5568; }
.content { flex-grow: 1; padding: 30px; background-color: #2d3748; } /* Main content area darker */
.content-card { background-color: #1a202c; border-radius: 8px; padding: 20px 30px; box-shadow: 0 2px 10px rgba(0,0,0,0.2); border: 1px solid #4a5568; }
.content-card h1, .content-card h2 { color: #9ae6b4; margin-top: 0; border-bottom: 1px solid #4a5568; padding-bottom: 10px; }

/* Admin Table Styles */
table { width: 100%; border-collapse: collapse; margin-top: 20px; background-color: #2d3748; color: #e2e8f0; }
th, td { padding: 12px; border: 1px solid #4a5568; text-align: left; }
th { background-color: #4a5568; color: #e2e8f0; font-weight: bold; }
tr:nth-child(even) { background-color: #2c3546; } /* Slightly different dark for even rows */
td a { color: #48bb78; }
td a:hover { color: #9ae6b4; }

/* Admin Button Styles */
.btn { padding: 8px 12px; border-radius: 4px; text-decoration: none; color: #1a202c; display: inline-block; font-size: 0.9em; border: none; cursor: pointer; font-weight: bold; transition: background-color 0.2s, color 0.2s; }
.btn-edit { background-color: #38a169; } /* Green */
.btn-edit:hover { background-color: #48bb78; }
.btn-delete { background-color: #c53030; color: white; } /* Red */
.btn-delete:hover { background-color: #e53e3e; }
.btn-add { background-color: #38a169; } /* Green */
.btn-add:hover { background-color: #48bb78; }

/* Admin Form Styles */
.form-group { margin-bottom: 15px; }
.form-group label { display: block; margin-bottom: 5px; font-weight: bold; color: #cbd5e0; }
.form-group input[type="text"],
.form-group input[type="url"],
.form-group input[type="date"],
.form-group input[type="number"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #4a5568;
    border-radius: 4px;
    box-sizing: border-box;
    background-color: #2d3748; /* Dark input background */
    color: #e2e8f0; /* Light input text */
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #48bb78; /* Green border on focus */
    box-shadow: 0 0 0 2px rgba(72, 187, 120, 0.3);
}
.form-group small { color: #a0aec0; font-size: 0.8em; }

/* Alert / Message Boxes */
.alert { padding: 15px; margin-bottom: 20px; border-radius: 4px; border: 1px solid transparent; }
.alert-error { background-color: #fed7d7; border-color: #f56565; color: #c53030; }
.alert-success { background-color: #c6f6d5; border-color: #68d391; color: #2f855a; }
.alert a { font-weight: bold; text-decoration: underline; }

/* Prose styles for article content */
.prose { max-width: none; }
.prose h1, .prose h2, .prose h3 { color: #9ae6b4; }
.prose p, .prose li { color: #cbd5e0; }
.prose a { color: #68d391; }
.prose strong { color: #e2e8f0; }
.prose blockquote { border-left-color: #4a5568; color: #a0aec0; }
.prose img, .prose video, .prose iframe { border-radius: 8px; max-width: 100%; height: auto; margin-top: 1em; margin-bottom: 1em; }

/* Utility Classes */
.mb-4 { margin-bottom: 1rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-12 { margin-bottom: 3rem; }
.mt-8 { margin-top: 2rem; }
.text-center { text-align: center; }
/* Add more basic utility classes if needed */

.pagination-container {
  display: flex;
  justify-content: center;
  margin: 40px 0;
  width: 100%;
}

.pagination {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  justify-content: center;
  align-items: center;
}

.page-btn {
  background: linear-gradient(145deg, #111827, #1f2937);
  color: #d1fae5;
  border: 1px solid #10b981;
  padding: 8px 14px;
  border-radius: 10px;
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.5px;
  transition: all 0.25s ease;
  box-shadow: 0 0 8px rgba(16, 185, 129, 0.3);
}

.page-btn:hover {
  background: #10b981;
  color: #0f172a;
  box-shadow: 0 0 14px #10b981;
  transform: translateY(-2px);
}

.page-btn.active {
  background: #10b981;
  color: #0f172a;
  font-weight: bold;
  pointer-events: none;
  box-shadow: 0 0 15px #10b981, 0 0 25px #10b98166;
}

.dots {
  color: #6b7280;
  font-size: 15px;
  padding: 6px 10px;
  letter-spacing: 2px;
}
/* Pulsing glow for upcoming events */
.event-glow {
    position: relative;
    transition: box-shadow 0.3s ease-in-out;
}
.event-glow:hover {
    box-shadow: 0 0 15px #38b2ac, 0 0 30px #38b2ac, 0 0 45px #38b2ac;
}
.badge-glow {
    animation: pulse 2s infinite;
}
@keyframes pulse {
    0%, 100% { box-shadow: 0 0 5px #38b2ac; }
    50% { box-shadow: 0 0 15px #38b2ac; }
}
/* --- Events Section Styling (Admin & Public) --- */

/* Event Cards (front-facing display) */
.event-card {
    background-color: #1a202c;
    border: 1px solid #2d3748;
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 0 10px rgba(72, 187, 120, 0.2);
    transition: transform 0.2s ease, box-shadow 0.3s ease;
}
.event-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 0 20px rgba(72, 187, 120, 0.4);
}
.event-card h3 {
    color: #9ae6b4;
    font-size: 1.2rem;
    margin-bottom: 0.6rem;
}
.event-card .event-date {
    font-size: 0.9rem;
    color: #a0aec0;
    margin-bottom: 0.8rem;
}
.event-card p {
    color: #cbd5e0;
}
.event-card .event-link {
    display: inline-block;
    margin-top: 0.8rem;
    color: #48bb78;
    font-weight: bold;
}
.event-card .event-link:hover {
    color: #9ae6b4;
}

/* --- Admin Event List Table --- */
.admin-events-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}
.admin-events-table th,
.admin-events-table td {
    padding: 12px;
    border: 1px solid #4a5568;
}
.admin-events-table th {
    background-color: #2d3748;
    color: #9ae6b4;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}
.admin-events-table td {
    background-color: #1a202c;
    color: #e2e8f0;
}
.admin-events-table tr:hover td {
    background-color: #2d3748;
}

/* --- Event Import Progress --- */
.event-import-log {
    background-color: #1a202c;
    border: 1px solid #4a5568;
    border-radius: 6px;
    padding: 1rem;
    margin-top: 1.5rem;
    max-height: 400px;
    overflow-y: auto;
    font-family: monospace;
    color: #9ae6b4;
}
.event-import-log strong {
    color: #48bb78;
}
.event-import-log .error {
    color: #f56565;
}
.event-import-log .success {
    color: #68d391;
}

/* --- Import Button --- */
.btn-import {
    background-color: #38a169;
    color: #1a202c;
    font-weight: bold;
    padding: 10px 16px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 0 8px rgba(72, 187, 120, 0.3);
}
.btn-import:hover {
    background-color: #48bb78;
    box-shadow: 0 0 12px rgba(72, 187, 120, 0.5);
}

/* --- Event Glow Badges --- */
.event-badge {
    display: inline-block;
    padding: 4px 10px;
    background-color: #4a5568;
    color: #e2e8f0;
    border-radius: 6px;
    font-size: 0.55rem;
    margin-right: 6px;
    transition: background-color 0.2s ease;
}
.event-badge:hover {
    background-color: #718096;
}

/* Animated event glow for active/upcoming */
.event-glow {
    animation: eventPulse 2s infinite;
}
@keyframes eventPulse {
    0%, 100% {
        box-shadow: 0 0 5px #48bb78, 0 0 10px rgba(72,187,120,0.5);
    }
    50% {
        box-shadow: 0 0 15px #48bb78, 0 0 30px rgba(72,187,120,0.4);
    }
}

/* --- Countdown Timer Styles (FIXED) --- */
.countdown-timer {
    display: flex;
    width: 100%;
    justify-content: space-around; /* Distribute space evenly */
    gap: 0.5rem; /* Small gap between items */
    background: rgba(0, 0, 0, 0.2); /* Slight background for contrast */
    padding: 1rem 0.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.countdown-timer > div {
    flex: 1; /* Make each timer item equal width */
    text-align: center;
    min-width: 0; /* Allow shrinking below content size if needed */
}

.cd-days, .cd-hours, .cd-mins, .cd-secs {
    font-size: 1.5rem; /* Default size */
    font-weight: bold;
    color: #fff;
    line-height: 1;
    display: block; /* Ensure it's on its own line */
    margin-bottom: 0.25rem;
}

.countdown-timer div {
    font-size: 0.875rem; /* Label size */
    color: #a0aec0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

/* Mobile adjustments */
@media (max-width: 640px) {
    .cd-days, .cd-hours, .cd-mins, .cd-secs {
        font-size: 1.25rem; /* Smaller numbers on mobile */
    }
    .countdown-timer div {
        font-size: 0.75rem; /* Smaller labels on mobile */
    }
}
/* Guide Container */
.guide-container {
    background: #f9f9f9; /* Light gray background for contrast */
    padding: 20px;
    border-radius: 8px;
    margin-top: 20px;
}

/* Island/Chapter Grouping */
.island-group {
    margin-bottom: 25px;
    border-left: 4px solid #333;
    padding-left: 15px;
}

.island-title {
    color: #444;
    margin-bottom: 10px;
}

/* Mission List styling */
.mission-list {
    list-style: none;
    padding: 0;
}

.mission-item {
    background: white;
    padding: 10px 15px;
    margin-bottom: 8px;
    border-radius: 4px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.mission-title {
    display: block;
    font-size: 1.1em;
}

.mission-objective {
    color: #666;
    font-size: 0.9em;
    margin: 5px 0 0 0;
}

/* Mission Types - Badges */
.mission-type {
    display: inline-block;
    font-size: 0.7em;
    text-transform: uppercase;
    padding: 2px 6px;
    border-radius: 3px;
    color: white;
    float: right;
}
/* Accordion Styles */
.island-title.island-trigger {
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
    transition: background-color 0.2s;
    padding: 10px;
    border-radius: 5px;
}

.island-title.island-trigger:hover {
    background-color: #3d495d; /* Slightly lighter than main background */
}

.chevron {
    transition: transform 0.3s ease;
    font-size: 0.8em;
    color: #a0aec0;
}

/* Collapsed State */
.island-group.collapsed .mission-list {
    display: none;
}

.island-group.collapsed .chevron {
    transform: rotate(-90deg);
}


/* Type-specific colors */
.type-main .mission-type { background-color: #d9534f; } /* Red for main story */
.type-side .mission-type { background-color: #5bc0de; } /* Blue for side missions */
.type-phone .mission-type { background-color: #5cb85c; } /* Green for phone/special */
.type-collectible .mission-type { background-color: #f0ad4e; } /* Orange for collectibles */

.company-logo {
    width: 100%;
    max-width: 400px; /* or whatever width you prefer */
    height: auto;
    display: block;
    margin-bottom: 1rem;
    
    /* Optional: make the background blend better */
    background-color: transparent; /* keeps white logos visible */
    object-fit: contain; /* ensures the whole logo fits in the box */
    border-radius: 0.5rem; /* optional, makes it look cleaner */
}