/* NAMESPACED STYLES FOR APPLEADS - NO DUPLICATES */
.appleads {
  font-family: 'Inter', sans-serif;
  margin: 0;
  background-color: var(--body-color);
  color: var(--text-color);
}

/* HEADER STYLES - NAMESPACED */
.appleads .appleads-header {
  width: 100%;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  position: fixed;
  top: 0;
  left: 0;
  z-index: 100;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border-bottom: 1px solid #e2e8f0;
}

.appleads .appleads-nav {
  height: 4.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Ensure actions sit to the right and never overlap logo */
.appleads .appleads-nav > *:first-child { flex: 0 0 auto; }
.appleads .appleads-nav > *:last-child { flex: 0 0 auto; }
.appleads .appleads-nav { gap: .5rem; }

.appleads .appleads-container {
  max-width: 90%;
  margin-left: auto;
  margin-right: auto;
  padding-left: 1rem;
  padding-right: 1rem;
}

.appleads .appleads-nav__logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
}

.appleads .appleads-nav__logo-img {
  height: 40px;
  width: auto;
}

.appleads .appleads-nav__logo-text {
  font-size: 1.5rem;
  font-weight: 700;
  font-family: 'Space Grotesk', sans-serif;
  color: #0f172a;
}

.appleads .appleads-nav__actions {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-left: auto;
}

.appleads .appleads-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  font-weight: 600;
  border-radius: 0.5rem;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-align: center;
  cursor: pointer;
  border: 1px solid transparent;
  font-size: 0.95rem;
  line-height: 1.1;
  text-decoration: none;
}

/* Mobile tweaks */
@media (max-width: 768px) {
  .appleads .appleads-nav {
    height: auto;
    padding: 0.75rem 0;
  }
  .appleads .appleads-nav__logo-img {
    height: 32px;
  }
  .appleads .appleads-nav__actions {
    gap: 0.5rem;
    display: flex;
    flex-wrap: nowrap;
    margin-left: auto;
  }
  .appleads .appleads-btn {
    padding: 0.4rem 0.75rem !important;
    font-size: 0.875rem !important; /* 14px - readable size */
    border-radius: 0.375rem !important;
    border-width: 1px !important;
    white-space: nowrap;
    min-width: auto !important;
  }
}

/* Google button */
.appleads .appleads-btn--google {
  background: #ffffff;
  color: #0f172a;
  border: 1px solid #e2e8f0;
}
.appleads .appleads-btn--google:hover { background: #f8fafc; }
.appleads .google-icon { flex-shrink: 0; }

/* Very small screens: Keep buttons small but readable */
@media (max-width: 480px) {
  .appleads .appleads-container {
    padding-left: 0.75rem;
    padding-right: 0.75rem;
  }
  .appleads .appleads-nav__logo-img {
    height: 28px;
  }
  /* Make buttons smaller on very small screens */
  .appleads .appleads-nav__actions .appleads-btn {
    padding: 0.35rem 0.6rem !important;
    font-size: 0.8rem !important;
  }
}

.appleads .appleads-btn--secondary {
  background: transparent;
  color: #6366f1;
  border-color: #6366f1;
}

.appleads .appleads-btn--secondary:hover {
  background: #6366f1;
  color: #ffffff;
}

/* MAIN CONTENT SPACING */
.appleads main {
  padding: 6rem 20px 20px 20px;
  max-width: 800px;
  margin: auto;
}

/* BASIC FORM STYLES */
.appleads form {
  display: flex;
  flex-direction: column;
  gap: 15px;
}

.appleads label {
  font-weight: 500;
  color: var(--text-color);
}

.appleads input,
.appleads select,
.appleads textarea {
  padding: 12px;
  border: 1px solid var(--border-color);
  border-radius: 4px;
  font-family: inherit;
}

.appleads button {
  padding: 12px 24px;
  background: var(--primary-color);
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 500;
}

.appleads button:hover {
  background: var(--primary-color-alt);
}

/* LOADING STYLES */
.appleads .appleads-loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.appleads .appleads-loading-spinner {
  width: 40px;
  height: 40px;
  border: 4px solid #f3f3f3;
  border-top: 4px solid var(--primary-color);
  border-radius: 50%;
  animation: appleads-spin 1s linear infinite;
}

@keyframes appleads-spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

.appleads .appleads-loading-text {
  color: white;
  margin-top: 20px;
  text-align: center;
  font-size: 16px;
}