:root {
  --primary-accent: #007bff;
  --hover-accent: #38bdf8;
  --bg-dark-navy: #0b1426;
  --card-bg: rgba(11, 20, 38, 0.85);
  --border-color: #1e293b;
  --text-main: #ffffff;
  --text-muted: #94a3b8;
  --text-sub: #cbd5e1;
}

body {
  position: relative;
  margin: 0;
  padding: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: var(--bg-dark-navy);
  color: var(--text-main);
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  overflow-x: hidden;
}

/* Background image overlay */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: url("phone.jpg");
  background-repeat: no-repeat;
  background-position: center;
  background-size: cover;
  opacity: 0.25;
  z-index: -1;
}

/* Top Announcement Banner */
.description {
  background-color: #090977;
  color: var(--text-main);
  font-size: clamp(0.75rem, 2vw, 0.85rem);
  font-weight: 600;
  letter-spacing: 0.5px;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 36px;
  padding: 6px 16px;
  box-sizing: border-box;
}

/* Navigation Bar */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background-color: var(--bg-dark-navy);
  padding: 12px clamp(15px, 4vw, 40px);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
  position: sticky;
  top: 0;
  z-index: 100;
  gap: 16px;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-shrink: 0;
}

.logo {
  height: clamp(30px, 4vw, 40px);
  width: auto;
  object-fit: contain;
}

.brand-name {
  color: var(--text-main);
  font-weight: 800;
  font-size: clamp(1.1rem, 2.5vw, 1.3rem);
  letter-spacing: 1px;
}

/* Nav Controls */
.nav-controls {
  display: flex;
  align-items: center;
  gap: clamp(12px, 2.5vw, 28px);
  position: relative;
}

.nav-links {
  display: flex;
  gap: clamp(10px, 2vw, 24px);
  align-items: center;
}

.nav-links a {
  color: var(--text-sub);
  text-decoration: none;
  font-size: clamp(0.75rem, 1.6vw, 0.95rem);
  font-weight: 500;
  white-space: nowrap;
  transition: color 0.2s ease-in-out;
}

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

/* Search Icon Toggle */
.icon-btn {
  background: none;
  border: none;
  color: var(--text-main);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.2s;
  user-select: none;
}

.icon-btn:hover {
  opacity: 0.8;
}

/* Search Dropdown Box */
.search-dropdown {
  position: absolute;
  top: 45px;
  right: 0;
  width: 280px;
  padding: 10px;
  background: #091527;
  border: 1px solid #1e293b;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  display: flex;
  gap: 8px;
  
  /* Hidden state */
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px);
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1000;
}

/* Toggle functionality using sibling selector */
#search-toggle:checked ~ .search-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.search-dropdown input {
  flex: 1;
  padding: 8px 12px;
  background: #050b14;
  border: 1px solid #2ee0df;
  border-radius: 6px;
  color: var(--text-main);
  outline: none;
  font-size: 14px;
}

.search-dropdown input::placeholder {
  color: var(--text-muted);
}

.search-dropdown button {
  padding: 8px 14px;
  border: none;
  border-radius: 6px;
  background: var(--primary-accent);
  color: white;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.search-dropdown button:hover {
  opacity: 0.9;
}

/* Main Dashboard Container */
.middle {
  flex: 1;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: clamp(15px, 3vw, 30px) clamp(12px, 2.5vw, 20px);
  box-sizing: border-box;
}

/* Card Grid Layout */
.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: clamp(16px, 3vw, 24px);
  display: flex;
  align-items: center;
  gap: 20px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
  backdrop-filter: blur(4px);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.4);
}

.card-img {
  width: 40%;
  max-width: 180px;
  height: 120px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border-color);
  flex-shrink: 0;
}

.card-content {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.card-content h1 {
  margin: 0;
  font-size: clamp(1.1rem, 2.2vw, 1.5rem);
  color: var(--text-main);
}

.card-content h4 {
  margin: 0;
  font-weight: 400;
  font-size: clamp(0.8rem, 1.8vw, 0.95rem);
  color: var(--text-sub);
  line-height: 1.3;
}

.store-link {
  text-decoration: none;
  width: fit-content;
  margin-top: 6px;
}

.store {
  border-radius: 6px;
  padding: 8px 16px;
  min-width: 100px;
  background-color: var(--primary-accent);
  border: none;
  color: var(--text-main);
  font-weight: 600;
  font-size: clamp(0.8rem, 1.5vw, 0.9rem);
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.1s ease;
}

.store:hover {
  background-color: #0056b3;
  transform: translateY(-1px);
}

/* Site Footer */
.site-footer {
  background-color: #060c18;
  color: var(--text-sub);
  padding-top: 40px;
  border-top: 1px solid var(--border-color);
  margin-top: auto;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px 40px 20px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 30px;
}

.footer-col h4 {
  color: var(--text-main);
  font-size: 1.05rem;
  margin-bottom: 16px;
  position: relative;
}

.footer-col h4::after {
  content: '';
  display: block;
  width: 30px;
  height: 2px;
  background-color: var(--primary-accent);
  margin-top: 6px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
}

.footer-logo {
  height: 35px;
  width: auto;
}

.footer-brand h3 {
  color: var(--text-main);
  margin: 0;
}

.slogan {
  font-size: 0.85rem;
  color: var(--text-muted);
  line-height: 1.4;
}

.contact-info, .footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
}

.contact-info li, .footer-col p {
  font-size: 0.88rem;
  margin-bottom: 8px;
  line-height: 1.5;
}

.footer-links li {
  margin-bottom: 8px;
}

.footer-links a {
  color: var(--text-sub);
  text-decoration: none;
  font-size: 0.88rem;
  transition: color 0.2s ease;
}

.footer-links a:hover {
  color: var(--hover-accent);
}

.footer-bottom {
  background-color: #030712;
  text-align: center;
  padding: 15px 20px;
  font-size: 0.8rem;
  color: #64748b;
  border-top: 1px solid #0f172a;
}

/* Mobile & Tablet Adaptations */
@media (max-width: 768px) {
  .navbar {
    flex-direction: column;
    padding: 12px 16px;
    gap: 10px;
  }

  .nav-controls {
    width: 100%;
    justify-content: center;
    flex-wrap: nowrap;
    gap: 10px;
  }

  .search-dropdown {
    right: 50%;
    transform: translate(50%, -8px);
  }

  #search-toggle:checked ~ .search-dropdown {
    transform: translate(50%, 0);
  }

  .card {
    flex-direction: column;
    text-align: center;
    padding: 20px 16px;
  }

  .card-img {
    width: 100%;
    max-width: 220px;
    height: 140px;
  }

  .card-content {
    align-items: center;
  }
}

@media (max-width: 480px) {
  .nav-links a {
    font-size: 0.72rem;
  }

  .product-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .footer-container {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}