/* ===== MODERN DARK THEME - "THE OBSERVATORY" ===== */
/* 1. BASE RESET & GLOBAL STYLES */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --color-bg-dark: #0c1d1c; /* Deep, dark blue-black - main background */
    --color-bg-card: #152b2a; /* Slightly lighter dark blue for cards/nav */
    --color-primary: #2a9d8f; /* Vibrant purple (modern, energetic) */
    --color-accent: #f2ab39; /* Bright cyan for highlights & calls to action */
    --color-text: #e8ede8; /* Light grey-blue for text */
    --color-text-muted: #6b8e8a; /* Muted text for less important info */
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--color-text);
    background-color: var(--color-bg-dark);
    background-image: 
        radial-gradient(circle at 15% 50%, rgba(46, 65, 114, 0.25) 0%, transparent 25%),
        radial-gradient(circle at 85% 30%, rgba(126, 111, 255, 0.1) 0%, transparent 25%);
    background-attachment: fixed;
    min-height: 100vh;
}

/* 2. TYPOGRAPHY */
h1, h2, h3, h4 {
    font-weight: 600;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.hero h1 {
    font-size: 3.5rem;
    background: linear-gradient(90deg, var(--color-text) 0%, var(--color-accent) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin-bottom: 1.5rem;
}

.hero p {
    font-size: 1.5rem;
    color: var(--color-text-muted);
    margin-bottom: 2.5rem;
    max-width: 600px;
}

/* 3. NAVIGATION */
header {
    background-color: rgba(19, 29, 50, 0.8); /* var(--color-bg-card) with transparency */
    backdrop-filter: blur(10px); /* Frosted glass effect */
    padding: 1rem 2rem;
    position: sticky;
    top: 0;
    z-index: 100;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
}

/* 3.1 Logo Styling */
.logo {
    display: flex;
    align-items: center;
    text-decoration: none;
}
/* Style for the logo image itself */
.logo-image {
    height: 2.5rem; /* Adjust this value to control the logo size */
    width: auto;
}
/* Make the logo in the hero section larger */
.hero .logo-image.hero-logo {
    height: min(24rem, 40vh); /* Uses the smaller of 24rem or 40% of viewport height */
    max-height: 24rem;
    min-height: 8rem;
  }

.hero .logo {
    margin-bottom: 2rem; /* Adjust this value to control space between logo and text */
    margin-top: 0rem; /* Pull logo closer to top */
  }

nav ul { 
    list-style: none; 
    display: flex; 
    gap: 2rem;
}
nav ul li a {
    color: var(--color-text-muted);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
    padding: 0.5rem 0;
    position: relative;
}
nav ul li a:hover {
    color: var(--color-text);
}
nav ul li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--color-accent);
    transition: width 0.3s ease;
}
nav ul li a:hover::after {
    width: 100%;
}

/* 4. HERO SECTION */
.hero {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 8rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
    min-height: 10vh; /* Makes the hero section take the full viewport height */
}

/* 5. BUTTON */
.button {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: linear-gradient(90deg, var(--color-primary) 0%, var(--color-accent) 100%);
    color: white;
    text-decoration: none;
    font-weight: 600;
    border-radius: 50px; /* Pill shape */
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(126, 111, 255, 0.3);
}
.button:hover {
    transform: translateY(-3px);
    box-shadow: 0 7px 20px rgba(126, 111, 255, 0.5);
}

/* 6. MAIN CONTENT & FOOTER */
.content {
    padding: 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

footer {
    background-color: var(--color-bg-card);
    color: var(--color-text-muted);
    text-align: center;
    padding: 2rem;
    margin-top: 4rem;
}
/* ===== SEARCH PAGE STYLES ===== */
.search-hero {
    padding: 4rem 2rem;
    text-align: center;
    background: var(--color-bg-card);
    margin: 1rem;
    border-radius: 12px;
}

.search-container {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin: 2rem 0;
    flex-wrap: wrap;
}

.search-input-group {
    position: relative;
    display: flex;
    align-items: center;
}
.search-input-group i {
    position: absolute;
    left: 1rem;
    color: var(--color-text-muted);
}
#searchInput, #codeSearchInput {
    padding: 1rem 1rem 1rem 3rem;
    border: 1px solid var(--color-primary);
    border-radius: 50px;
    background: var(--color-bg-dark);
    color: var(--color-text);
    min-width: 300px;
}
.live-filters {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
}
.filter-chip {
    padding: 0.5rem 1.25rem;
    background: transparent;
    color: var(--color-accent);
    border: 1px solid var(--color-accent);
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
}
.filter-chip:hover, .filter-chip.active {
    background: var(--color-accent);
    color: var(--color-bg-dark);
}

/* KAD Card Styles */
.kad-results {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 1.5rem;
    padding: 2rem;
}
.kad-card {
    background: var(--color-bg-card);
    padding: 1.5rem;
    border-radius: 8px;
    border-left: 4px solid var(--color-primary);
    transition: transform 0.3s ease;
}
.kad-card:hover {
    transform: translateY(-5px);
}
.kad-card-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 1rem;
}
.kad-code {
    font-family: monospace;
    font-size: 1.1rem;
    color: var(--color-accent);
}
.briefcase-btn {
    background: none;
    border: 1px solid var(--color-text-muted);
    color: var(--color-text-muted);
    border-radius: 50%;
    width: 30px;
    height: 30px;
    cursor: pointer;
}
.briefcase-btn:hover {
    border-color: var(--color-accent);
    color: var(--color-accent);
}
.kad-metrics {
    display: flex;
    gap: 1rem;
    margin: 1rem 0;
}
.metric {
    font-size: 0.85rem;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    background: rgba(126, 111, 255, 0.1);
}

.no-results {
    text-align: center;
    padding: 2rem;
    color: var(--color-text-muted);
    font-style: italic;
    grid-column: 1 / -1;
}
/* Autocomplete Styles */
.autocomplete-container {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-bg-card);
    border: 1px solid var(--color-primary);
    border-radius: 8px;
    max-height: 300px;
    overflow-y: auto;
    z-index: 1000;
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}

.autocomplete-item {
    padding: 0.75rem 1rem;
    cursor: pointer;
    border-bottom: 1px solid rgba(126, 111, 255, 0.1);
    transition: background-color 0.2s ease;
}

.autocomplete-item:hover {
    background-color: rgba(126, 111, 255, 0.1);
}

.autocomplete-item:last-child {
    border-bottom: none;
}

.suggestion-text {
    color: var(--color-text);
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
}

.suggestion-code {
    color: var(--color-accent);
    font-size: 0.8rem;
    font-family: monospace;
}

.search-input-group {
    position: relative;
}
/* Language Switcher */
.language-switcher {
    display: flex;
    gap: 0.5rem;
    margin-left: 2rem;
}

.language-btn {
    background: none;
    border: 1px solid var(--color-text-muted);
    color: var(--color-text-muted);
    padding: 0.5rem 1rem;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.9rem;
}

.language-btn:hover,
.language-btn.active {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: white;
}

/* Ensure elements with translations are properly styled */
[data-translate] {
    transition: opacity 0.3s ease;
}

body.changing-language [data-translate] {
    opacity: 0.8;
}
/* Responsive logo adjustments */
@media (max-width: 1200px) {
    .hero .logo-image.hero-logo {
      height: 20rem;
    }
  }
  
  @media (max-width: 768px) {
    .hero .logo-image.hero-logo {
      height: 14rem;
    }
  }
  
  @media (max-width: 480px) {
    .hero .logo-image.hero-logo {
      height: 10rem;
      margin-bottom: 1.5rem;
    }


  }
