@tailwind base;
@tailwind components;
@tailwind utilities;

@layer base {
  :root {
    --background: 0 0% 100%;
    --foreground: 222.2 84% 4.9%;
    --card: 0 0% 100%;
    --card-foreground: 222.2 84% 4.9%;
    --popover: 0 0% 100%;
    --popover-foreground: 222.2 84% 4.9%;
    --primary: 221.2 83.2% 53.3%;
    --primary-foreground: 210 40% 98%;
    --secondary: 210 40% 96.1%;
    --secondary-foreground: 222.2 47.4% 11.2%;
    --muted: 210 40% 96.1%;
    --muted-foreground: 215.4 16.3% 46.9%;
    --accent: 210 40% 96.1%;
    --accent-foreground: 222.2 47.4% 11.2%;
    --destructive: 0 84.2% 60.2%;
    --destructive-foreground: 210 40% 98%;
    --border: 214.3 31.8% 91.4%;
    --input: 214.3 31.8% 91.4%;
    --ring: 221.2 83.2% 53.3%;
    --radius: 0.5rem;
  }
}

@layer components {
  /* Navigation page specific styles */
  .main-content {
    min-height: 0; /* Remove fixed min-height to prevent scrolling */
    flex: 1;
    display: flex;
    flex-direction: column;
  }

  .main-content .main {
    flex: 1;
    display: flex;
    flex-direction: column;
  }

  /* Ensure footer stays at bottom */
  .body-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
  }

  .body-wrapper > main {
    flex: 1;
  }

  /* Logo Header styles */
  .logo-header {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 2rem 0;
  }

  .logo-container {
    text-align: center;
  }

  .logo-img {
    max-width: 200px;
    width: 100%;
    height: auto;
    display: block;
    margin: 0 auto;
  }

  /* 403 Error Page styles */
  .error-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 300px);
    padding: 2rem 1rem;
  }

  .error-container {
    text-align: center;
    max-width: 500px;
    margin: 0 auto;
  }

  .error-code {
    font-size: 6rem;
    font-weight: 300;
    color: #000;
    margin-bottom: 1rem;
    line-height: 1;
  }

  .error-message {
    font-size: 1.5rem;
    font-weight: 500;
    color: #000;
    margin-bottom: 1rem;
  }

  .error-description {
    font-size: 1rem;
    color: #666;
    margin-bottom: 2rem;
    line-height: 1.5;
  }

  .home-button {
    display: inline-block;
    background-color: #4a5568;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.2s ease;
  }

  .home-button:hover {
    background-color: #2d3748;
  }

  /* Signed Out Page styles */
  .signed-out-page {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 300px);
    padding: 2rem 1rem;
  }

  .signed-out-container {
    text-align: center;
    max-width: 500px;
    margin: 0 auto;
  }

  .signed-out-message {
    font-size: 2rem;
    font-weight: 700;
    color: #000;
    margin-bottom: 2rem;
    font-family: serif;
  }

  .sign-in-actions {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
  }

  .sign-in-button {
    display: inline-block;
    background-color: #4a5568;
    color: white;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.2s ease;
    min-width: 150px;
  }

  .sign-in-button:hover {
    background-color: #2d3748;
  }

  .home-link-text {
    font-size: 1rem;
    color: #666;
  }

  .home-link {
    color: #4a5568;
    text-decoration: underline;
    transition: color 0.2s ease;
  }

  .home-link:hover {
    color: #2d3748;
  }

  /* Password Reset Page styles */
  .reset-password-page p {
    list-style: none;
    margin: 0;
    padding: 0;
  }

  .reset-password-page .section-wrapper p {
    margin-bottom: 1rem;
  }

  /* Enhanced Password Reset Page styles */
  .reset-password-page {
    min-height: calc(100vh - 300px);
    padding: 2rem 1rem;
    background-color: #ffffff;
  }

  .reset-password-page .section-wrapper {
    max-width: 500px;
    margin: 0 auto;
    padding: 2rem;
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  }

  .reset-password-page h1 {
    font-size: 2rem;
    font-weight: 700;
    color: #000;
    margin-bottom: 1rem;
    font-family: serif;
    text-align: left;
  }

  .reset-password-page p {
    font-size: 1rem;
    color: #333;
    line-height: 1.6;
    margin-bottom: 1.5rem;
    text-align: left;
  }

  /* Form styling */
  .hs-membership-reset-request__form-container {
    margin-top: 2rem;
  }

  .form-wrapper--reset-password-request {
    margin-bottom: 2rem;
  }

  /* Input field styling */
  .form-wrapper--reset-password-request input[type="email"] {
    width: 100%;
    padding: 0.75rem;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 1rem;
    margin-bottom: 1rem;
  }

  .form-wrapper--reset-password-request input[type="email"]:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
  }

  /* Button styling */
  .form-wrapper--reset-password-request button[type="submit"] {
    background-color: #f3f4f6;
    color: #000;
    border: 1px solid #d1d5db;
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
  }

  .form-wrapper--reset-password-request button[type="submit"]:hover {
    background-color: #e5e7eb;
    border-color: #9ca3af;
  }

  /* Sign in link styling */
  .hs-membership-reset-request__form-container p:last-child {
    text-align: left;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e5e7eb;
  }

  .hs-membership-reset-request__form-container a {
    color: #3b82f6;
    text-decoration: underline;
    transition: color 0.2s ease;
  }

  .hs-membership-reset-request__form-container a:hover {
    color: #1d4ed8;
  }

  /* Success state styling */
  .section-wrapper--centered {
    text-align: center;
  }

  .section-wrapper--centered h1 {
    text-align: center;
    color: #059669;
    margin-bottom: 1rem;
  }

  .section-wrapper--centered p {
    text-align: center;
    color: #065f46;
    margin-bottom: 2rem;
  }

  .button-wrapper--membership-reset-password-success button {
    background-color: #3b82f6;
    color: white;
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
  }

  .button-wrapper--membership-reset-password-success button:hover {
    background-color: #1d4ed8;
  }
}
