/* ==========================================================================
   1. RESET & BASE STYLES
   ========================================================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, sans-serif;
  background: #f5f5f5;
  color: #222;
}

a {
  color: #2b2b2b;
  text-decoration: none;
  font-weight: bold;
}

p {
  margin-bottom: 20px;
  line-height: 1.8;
  font-size: 18px;
}

/* Typography Hierarchy */
h1 { font-size: 48px; color: #ff004c; font-weight: 700; }
h2 { font-size: 38px; color: #690120; font-weight: 700; }
h3 { font-size: 30px; color: #10024f; font-weight: 600; }
h4 { font-size: 24px; color: #8c3401; font-weight: 600; }
h5 { font-size: 20px; color: #047520; font-weight: 600; }
h6 { font-size: 16px; color: #5e004d; font-weight: 600; }

/* ==========================================================================
   2. HEADER & NAVIGATION
   ========================================================================== */
.header {
  position: fixed;
  top: 0;
  right: 0;
  width: 100%;
  height: 65px;
  background: #fff;
  border-bottom: 2px solid #ddd;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  z-index: 999;
}

.left-header, .right-header {
  display: flex;
  align-items: center;
}

.logo {
  width: 120px;
  height: 45px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ==========================================================================
   3. DESKTOP MENU & DROPDOWNS (Optimized & Cleaned)
   ========================================================================= */
.desktop-menu {
  display: flex;
  align-items: center;
  gap: 25px;
}

.desktop-menu a {
  text-decoration: none;
  color: #222;
  font-weight: bold;
  font-size: 15px;
}

/* Main Dropdown Container */
.dropdown {
  position: relative;
}

.dropdown-btn {
    position: absolute;
  top: 100%;
  right: 0;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  min-width: 280px;
  display: none;
  flex-direction: column;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  padding: 8px 0; /* Creates breathing room at top and bottom of the panel */
  z-index: 9999;
  overflow: hidden;
}

.mobile-dropdown-btn {
    position: absolute;
  top: 100%;
  right: 0;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  min-width: 280px;
  display: none;
  flex-direction: column;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  padding: 8px 0; /* Creates breathing room at top and bottom of the panel */
  z-index: 9999;
  overflow: hidden;
}

.mobile-sub-dropdown {
    position: absolute;
  top: 100%;
  right: 0;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  min-width: 280px;
  display: none;
  flex-direction: column;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  padding: 8px 0; /* Creates breathing room at top and bottom of the panel */
  z-index: 9999;
  overflow: hidden;
}


/* Dropdown Flyout Panel */
.dropdown-content {
  position: absolute;
  top: 100%;
  right: 0;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  min-width: 280px;
  display: none;
  flex-direction: column;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  padding: 8px 0; /* Creates breathing room at top and bottom of the panel */
  z-index: 9999;
  overflow: hidden;
}

/* Links inside Dropdown */
.dropdown-content a {
  padding: 12px 20px; /* Spacious internal padding */
  color: #334155;
  font-size: 14px;
  font-weight: 500;
  border-bottom: 1px solid #f1f5f9;
  white-space: nowrap;
  transition: all 0.2s ease-in-out; /* Smooth hover transition */
}

/* Remove the border from the very last link */
.dropdown-content a:last-child {
  border-bottom: none;
}

/* Interactive Hover State */
.dropdown-content a:hover {
  background: #f8fafc;
  color: #2563eb; /* Changes text to a clean modern blue */
  padding-left: 24px; /* Subtle elegant slide-right effect */
}

/* Show Dropdown on Hover */
.dropdown:hover > .dropdown-content {
  display: flex;
}

/* ==========================================================================
   SUB DROPDOWN (Nested Level 2)
   ========================================================================= */
.sub-dropdown {
  position: relative;
}

.sub-dropdown-btn {
  display: block;
}

/* Sub-Dropdown Flyout Panel */
.sub-dropdown-content {
  position: absolute;
  right: 100%;
  top: -8px; /* Perfectly aligns with top spacing of parent */
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  min-width: 280px;
  display: none;
  flex-direction: column;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
  padding: 8px 0;
}

.sub-dropdown-content a {
  padding: 12px 20px;
  color: #334155;
  font-size: 14px;
  font-weight: 500;
  border-bottom: 1px solid #f1f5f9;
  transition: all 0.2s ease-in-out;
}

.sub-dropdown-content a:last-child {
  border-bottom: none;
}

.sub-dropdown-content a:hover {
  background: #f8fafc;
  color: #2563eb;
  padding-left: 24px;
}

/* Show Sub-Dropdown on Hover */
.sub-dropdown:hover > .sub-dropdown-content {
  display: flex;
}

/* ==========================================================================
   4. MOBILE NAVIGATION & OVERLAY
   ========================================================================== */
.menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 30px;
  cursor: pointer;
}

.mobile-menu {
  position: fixed;
  top: 0;
  right: -260px;
  width: 250px;
  height: 100vh;
  background: #fff;
  box-shadow: 2px 0 10px rgba(0,0,0,0.2);
  padding-top: 90px;
  transition: 0.3s;
  z-index: 1000;
  display: flex;
  flex-direction: column;
}

.mobile-menu.active {
  right: 0;
}

.mobile-menu a {
  padding: 18px 25px;
  text-decoration: none;
  color: #222;
  border-bottom: 1px solid #eee;
  font-weight: bold;
}

.mobile-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: rgba(0,0,0,0.4);
  opacity: 0;
  visibility: hidden;
  transition: 0.3s;
  z-index: 998;
}

.mobile-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Mobile Dropdowns Toggled via JS */
.mobile-dropdown-content,
.mobile-sub-content {
  display: none;
  flex-direction: column;
}

.mobile-dropdown.active > .mobile-dropdown-content {
  display: flex;
}

.mobile-sub-dropdown.active > .mobile-sub-content {
  display: flex;
}

/* ==========================================================================
   5. LAYOUT & CONTENT PANELS
   ========================================================================== */
.main-container {
  max-width: 1400px;
  margin: auto;
  display: flex;
  gap: 30px;
  padding: 110px 20px 40px;
}

.content-area {
  flex: 1;
  background: #fff;
  padding: 30px;
  border: 1px solid #ddd;
}

.content-box {
  margin-top: 20px;
  padding: 15px;
  border: 2px dashed #aaa;
  min-height: 150px;
}

.sidebar {
  width: 320px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.side-box {
  background: #fff;
  border: 1px solid #ddd;
  min-height: 180px;
  padding: 20px;
}

.footer {
  text-align: center;
  padding: 25px;
  background: #fff;
  border-top: 1px solid #ddd;
  font-size: 18px;
}

/* ==========================================================================
   6. SIDEBAR COMPONENETS (Social & Apps)
   ========================================================================== */
.social-box h3 {
  margin-bottom: 20px;
  font-size: 22px;
}

.social-icons {
  display: flex;
  gap: 25px;
  align-items: center;
  flex-wrap: wrap;
}

.social-icons a {
  display: block;
  transition: 0.3s;
}

.social-icons a:hover {
  transform: scale(1.1);
}

.social-icons img {
  width: 50px;
  height: 50px;
  object-fit: contain;
}

.apps-box {
  background: #fff;
  padding: 15px;
}

.apps-title {
  text-align: center;
  margin-bottom: 20px;
  font-size: 40px;
  color: blue;
  text-decoration: underline;
}

.app-item {
  display: flex;
  align-items: center;
  gap: 20px;
  background: #edf0e4;
  border: 4px solid #111;
  border-radius: 25px;
  padding: 12px;
  margin-bottom: 15px;
  text-decoration: none;
  transition: 0.3s;
}

.app-item:hover {
  transform: scale(1.02);
}

.app-item img {
  width: 75px;
  height: 75px;
  border-radius: 50%;
  object-fit: cover;
  background: #fff;
}

.app-item span {
  flex: 1;
  text-align: center;
  font-size: 20px;
  font-weight: bold;
  color: darkgreen;
}

/* ==========================================================================
   7. NEWSLETTER SIGNUP (Mailchimp)
   ========================================================================== */
#mc_embed_signup {
  max-width: 420px;
  margin: 40px auto;
  padding: 35px 30px;
  background: linear-gradient(135deg, #0f172a, #1e293b);
  border-radius: 20px;
  box-shadow: 0 10px 35px rgba(0,0,0,0.25);
  font-family: Arial, sans-serif;
  color: #fff;
  text-align: center;
}

#mc_embed_signup h6 {
  font-size: 24px;
  margin-bottom: 25px;
  line-height: 1.5;
  color: #ffffff;
  font-weight: 700;
}

#mc_embed_signup label {
  display: block;
  margin-bottom: 10px;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #cbd5e1;
  text-align: left;
}

#mc_embed_signup input[type="email"] {
  width: 100% !important;
  height: 52px !important;
  border: none;
  border-radius: 12px;
  padding: 0 18px;
  font-size: 16px;
  outline: none;
  background: #f8fafc;
  color: #111827;
  box-sizing: border-box;
  transition: all 0.3s ease;
}

#mc_embed_signup input[type="email"]:focus {
  box-shadow: 0 0 0 4px rgba(59,130,246,0.35);
}

#mc_embed_signup .button {
  width: 100%;
  height: 52px;
  margin-top: 20px;
  border: none;
  border-radius: 12px;
  background: linear-gradient(135deg, #3b82f6, #2563eb);
  color: #fff;
  font-size: 17px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
}

#mc_embed_signup .button:hover {
  transform: translateY(-2px);
  background: linear-gradient(135deg, #2563eb, #1d4ed8);
  box-shadow: 0 8px 20px rgba(37,99,235,0.35);
}

#mc_embed_signup .mc-field-group {
  margin-bottom: 15px;
}

/* ==========================================================================
   8. MEDIA QUERIES (Responsive Design)
   ========================================================================== */
@media (max-width: 900px) {
  .header {
    gap: 10px;
  }

  .desktop-menu {
    display: none;
  }

  .menu-btn {
    display: block;
  }

  .logo {
    width: 90px;
    height: 40px;
    font-size: 14px;
  }

  .main-container {
    flex-direction: column;
  }

  .content-area {
    order: 1;
  }

  .sidebar {
    order: 2;
    width: 100%;
  }
}

@media (max-width: 768px) {
  h1 { font-size: 24px; }
  h2 { font-size: 20px; }
  h3 { font-size: 16px; }
  h4 { font-size: 15px; }
  h5 { font-size: 14px; }
  h6 { font-size: 13px; }
}

@media (max-width: 700px) {
  .apps-title {
    font-size: 26px;
  }

  .app-item {
    gap: 12px;
    padding: 10px;
  }

  .app-item img {
    width: 60px;
    height: 60px;
  }

  .app-item span {
    font-size: 16px;
  }
}