/* HelloRun Theme Styles */
:root {
    /* Color Scheme */
    --orange: #FA9A4B;
    --soft-orange: #E0A46A;
    --light-blue: #8FD5EC;
    --sky-blue: #78C0E9;
    --warm-beige: #F2EAD3;
    --white: #FFFFFF;
    --dark-gray: #333333;
    --medium-gray: #666666;
    --light-gray: #F8F9FA;
    
    /* Typography */
    --heading-font: 'Poppins', sans-serif;
    --body-font: 'Inter', sans-serif;
    
    /* Spacing */
    --section-padding: 4rem 1.5rem;
    --container-width: 1200px;
    
    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.1);
    
    /* Border Radius */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: var(--body-font);
    color: var(--dark-gray);
    line-height: 1.6;
    background-color: var(--white);
    overflow-x: hidden;
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--heading-font);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

h1 {
    font-size: clamp(2.5rem, 5vw, 3.5rem);
    font-weight: 800;
}

h2 {
    font-size: clamp(2rem, 4vw, 2.5rem);
    position: relative;
    padding-bottom: 1rem;
    text-align: center;
}

h2:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: linear-gradient(90deg, var(--orange), var(--soft-orange));
    border-radius: 2px;
}

h3 {
    font-size: clamp(1.5rem, 3vw, 1.75rem);
    margin-bottom: 1rem;
}

p {
    margin-bottom: 1.5rem;
    font-size: clamp(1rem, 2vw, 1.1rem);
}

/* Navigation - Mobile First Approach */
.nav {
    background-color: var(--white);
    box-shadow: var(--shadow-sm);
    padding: 1rem 1.5rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: all 0.3s ease;
}

.nav-container {
    max-width: var(--container-width);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 800;
    font-size: 1.5rem;
    color: var(--primary);
    text-decoration: none;
}

.logo-icon {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.logo:before {
    /* Remove the emoji pseudo-element */
    content: none;
}

.nav-links {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
    justify-content: center;
}

.nav-links a {
    color: var(--dark-gray);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    transition: color 0.3s ease;
    padding: 0.5rem 0.8rem;
    border-radius: var(--radius-sm);
}

.nav-links a:hover {
    color: var(--orange);
    background-color: rgba(250, 154, 75, 0.1);
}

.nav-notifications-link {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}

.nav-notification-badge {
    min-width: 1.2rem;
    height: 1.2rem;
    padding: 0 0.35rem;
    border-radius: 999px;
    background: #dc2626;
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
    line-height: 1.2rem;
    text-align: center;
}

/* Mobile Menu Button (Hidden by default, shown on small screens) */
.menu-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--dark-gray);
    cursor: pointer;
    padding: 0.5rem;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--light-blue) 0%, var(--sky-blue) 100%);
    color: var(--dark-gray);
    padding: clamp(4rem, 10vw, 8rem) 1.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='100' height='100' viewBox='0 0 100 100' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm-43-7c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm63 31c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM34 90c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zm56-76c1.657 0 3-1.343 3-3s-1.343-3-3-3-3 1.343-3 3 1.343 3 3 3zM12 86c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm28-65c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm23-11c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-6 60c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm29 22c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zM32 63c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm57-13c2.76 0 5-2.24 5-5s-2.24-5-5-5-5 2.24-5 5 2.24 5 5 5zm-9-21c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM60 91c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM35 41c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2zM12 60c1.105 0 2-.895 2-2s-.895-2-2-2-2 .895-2 2 .895 2 2 2z' fill='%2378C0E9' fill-opacity='0.1' fill-rule='evenodd'/%3E%3C/svg%3E");
    opacity: 0.1;
}

.hero h1 {
    color: var(--dark-gray);
    margin-bottom: 1.5rem;
    font-size: clamp(2.5rem, 6vw, 4rem);
    font-weight: 900;
}

.hero p {
    font-size: clamp(1.2rem, 3vw, 1.5rem);
    max-width: 800px;
    margin: 0 auto 3rem;
    color: var(--dark-gray);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: clamp(0.8rem, 2vw, 1rem) clamp(1.5rem, 4vw, 2.5rem);
    background: linear-gradient(135deg, var(--orange), var(--soft-orange));
    color: var(--white);
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    font-size: clamp(0.95rem, 2vw, 1.1rem);
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-family: var(--heading-font);
    text-transform: uppercase;
    letter-spacing: 1px;
    text-align: center;
    white-space: nowrap;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(250, 154, 75, 0.3);
    color: var(--white);
}

.btn-secondary {
    background: var(--sky-blue);
}

.btn-secondary:hover {
    box-shadow: 0 10px 20px rgba(120, 192, 233, 0.3);
}

/* Features Section */
.features {
    padding: var(--section-padding);
    background-color: var(--light-gray);
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature-card {
    background: var(--white);
    padding: clamp(1.5rem, 4vw, 2.5rem);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.feature-card:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 5px;
    height: 100%;
    background: linear-gradient(to bottom, var(--orange), var(--soft-orange));
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-lg);
}

.feature-card h3 {
    color: var(--dark-gray);
    margin-bottom: 1rem;
    font-size: clamp(1.3rem, 3vw, 1.5rem);
}

.feature-icon {
    margin-bottom: 1.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, rgba(250, 154, 75, 0.1), rgba(224, 164, 106, 0.1));
    border-radius: 50%;
    padding: 1rem;
}

.feature-icon i {
    width: 28px;
    height: 28px;
    color: var(--orange);
    stroke-width: 2px;
}

/* Why HelloRun Section */
.why-hellorun {
    padding: var(--section-padding);
    background-color: var(--white);
}

.why-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.quote-box {
    background: var(--warm-beige);
    padding: clamp(2rem, 5vw, 3rem);
    border-radius: var(--radius-lg);
    margin: 3rem 0;
    position: relative;
    overflow: hidden;
}

.quote-box:before {
    content: '"';
    position: absolute;
    top: -20px;
    left: 20px;
    font-size: clamp(6rem, 15vw, 8rem);
    font-family: var(--heading-font);
    color: var(--orange);
    opacity: 0.2;
    line-height: 1;
}

.quote-box p {
    font-size: clamp(1.3rem, 4vw, 1.5rem);
    font-style: italic;
    margin-bottom: 0;
    position: relative;
    z-index: 1;
    font-weight: 500;
}

/* For Runners & Organizers Section */
.audience {
    padding: var(--section-padding);
    background: linear-gradient(135deg, var(--light-blue) 0%, var(--sky-blue) 100%);
    color: var(--dark-gray);
}

.audience-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(350px, 100%), 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.audience-card {
    background: var(--white);
    padding: clamp(2rem, 4vw, 3rem);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.audience-card h3 {
    color: var(--orange);
    margin-bottom: 1.5rem;
    font-size: clamp(1.4rem, 3vw, 1.6rem);
}

.audience-card ul {
    list-style: none;
    margin-bottom: 2rem;
    flex-grow: 1;
}

.audience-card li {
    padding: 0.5rem 0;
    padding-left: 2rem;
    position: relative;
}

.audience-card li:before {
    content: '→';
    position: absolute;
    left: 0;
    color: var(--orange);
    font-weight: bold;
}

/* CTA Section */
.cta-section {
    padding: var(--section-padding);
    background-color: var(--warm-beige);
    text-align: center;
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
}

.cta-tagline {
    font-family: var(--heading-font);
    font-size: clamp(1.8rem, 4vw, 2rem);
    font-weight: 700;
    color: var(--dark-gray);
    margin-bottom: 2rem;
    letter-spacing: 1px;
}

/* Footer */
.footer {
    background-color: var(--dark-gray);
    color: var(--white);
    padding: clamp(3rem, 6vw, 4rem) 1.5rem 2rem;
}

.footer-content {
    max-width: var(--container-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(min(250px, 100%), 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.footer h3 {
    color: var(--white);
    margin-bottom: 1.5rem;
    font-size: clamp(1.3rem, 3vw, 1.5rem);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: var(--light-blue);
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 0.95rem;
}

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

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid var(--medium-gray);
    color: var(--medium-gray);
    font-size: 0.9rem;
}

/* Enhanced Mobile Responsiveness */
@media (max-width: 768px) {
    /* Navigation adjustments */
    .nav-container {
        flex-direction: row;
    }
    
    .menu-toggle {
        display: block;
    }
    
    .nav-links {
        display: none;
        width: 100%;
        flex-direction: row;
        align-items: center;
        gap: 0.25rem;
        margin-top: 0;
        padding-top: 0;
        border-top: none;
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .nav-links a {
        padding: 0.5rem 0.6rem;
        text-align: center;
        border-radius: var(--radius-sm);
        margin-bottom: 0;
        font-size: 0.85rem;
        white-space: nowrap;
    }
    
    /* Hero section adjustments */
    .hero {
        padding: 3rem 1rem;
    }
    
    .hero h1 {
        font-size: 2.2rem;
        line-height: 1.3;
    }
    
    .hero p {
        font-size: 1.1rem;
        margin-bottom: 2rem;
    }
    
    /* Feature grid adjustments */
    .feature-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .feature-card {
        padding: 1.5rem;
    }
    
    /* Audience grid adjustments */
    .audience-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .audience-card {
        padding: 1.5rem;
    }
    
    /* Quote box adjustments */
    .quote-box {
        padding: 2rem 1rem;
        margin: 2rem 0;
    }
    
    .quote-box p {
        font-size: 1.2rem;
    }
    
    /* Button adjustments */
    .btn {
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
        display: block;
    }
    
    /* Footer adjustments */
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-links {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }
    
    .footer-links li {
        margin-bottom: 0;
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: 2rem;
    }
    
    h2 {
        font-size: 1.75rem;
    }
    
    h3 {
        font-size: 1.3rem;
    }
    
    .container {
        padding: 0 1rem;
    }
    
    .feature-icon {
        width: 50px;
        height: 50px;
    }
    
    .feature-icon i {
        width: 24px;
        height: 24px;
    }
    
    .logo {
        font-size: 1.4rem;
    }
    
    .logo:before {
        font-size: 1.5rem;
    }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Touch-friendly tap targets */
@media (hover: none) and (pointer: coarse) {
    .btn,
    .nav-links a,
    .footer-links a {
        min-height: 44px;
        min-width: 44px;
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }
    
    .feature-card {
        cursor: default;
    }
    
    .feature-card:hover {
        transform: none;
    }
}

/* Print styles */
@media print {
    .nav,
    .btn,
    .footer {
        display: none;
    }
    
    body {
        font-size: 12pt;
        line-height: 1.5;
    }
    
    .container {
        max-width: 100%;
        padding: 0;
    }
}

/* Form Input Styles */
input[type="text"],
input[type="email"],
input[type="password"],
select,
textarea {
  width: 100%;
  padding: 0.875rem 1rem;
  border: 2px solid #e0e0e0;
  border-radius: 8px;
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  color: var(--text);
  background-color: #ffffff;
  transition: all 0.3s ease;
}

/* Focus State - Orange Glow */
input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--primary); /* #FA9A4B */
  box-shadow: 0 0 0 4px rgba(250, 154, 75, 0.15);
  background-color: #fffbf7; /* Subtle warm tint */
}

/* Hover State */
input[type="text"]:hover:not(:focus),
input[type="email"]:hover:not(:focus),
input[type="password"]:hover:not(:focus),
select:hover:not(:focus) {
  border-color: #c0c0c0;
}

/* Disabled State */
input:disabled,
select:disabled {
  background-color: #f5f5f5;
  cursor: not-allowed;
  opacity: 0.6;
}

/* Placeholder */
input::placeholder {
  color: #999;
  font-style: italic;
}

/* Valid Input (after validation) */
input:valid:not(:placeholder-shown) {
  border-color: #10b981; /* Green */
}

/* Form Labels */
label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
  color: var(--text);
  font-size: 0.875rem;
}

label .required {
  color: #e74c3c;
  margin-left: 2px;
}

/* Form Groups */
.form-group {
  margin-bottom: 1.5rem;
}

/* Password Input Wrapper */
.password-input {
  position: relative;
  display: flex;
  align-items: center;
}

.password-input input {
  padding-right: 3rem; /* Space for toggle button */
}

.toggle-password {
  position: absolute;
  right: 0.75rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  color: #666;
  transition: color 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.toggle-password:hover {
  color: var(--primary);
}

.toggle-password:focus {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: 4px;
}

/* User Menu Styles - Add after existing nav styles */
.user-menu {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-left: auto;
}

.user-greeting {
  color: var(--dark-gray);
  font-weight: 600;
  font-size: 0.95rem;
  white-space: nowrap;
}

.logout-form {
  margin: 0;
  padding: 0;
}

.btn-logout {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: transparent;
  border: 2px solid var(--orange);
  color: var(--orange);
  padding: 0.5rem 1rem;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: var(--heading-font);
  white-space: nowrap;
}

.btn-logout:hover {
  background: var(--orange);
  color: var(--white);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(250, 154, 75, 0.3);
}

.btn-logout i {
  width: 16px;
  height: 16px;
}

/* Nav User Section */
.nav-user {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-left: 0.5rem;
  padding-left: 1rem;
  border-left: 1px solid #e0e0e0;
}

.nav-username {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--dark-gray);
  white-space: nowrap;
}

.nav-logout-btn {
  background: transparent;
  color: var(--orange);
  border: 2px solid var(--orange);
  padding: 0.4rem 0.9rem;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  font-family: 'Inter', sans-serif;
}

.nav-logout-btn:hover {
  background: var(--orange);
  color: white;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(250, 154, 75, 0.3);
}

.nav-login-btn,
.nav-signup-btn {
  padding: 0.5rem 1.2rem;
  border-radius: 50px;
  font-weight: 600;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  text-decoration: none;
}

.nav-login-btn {
  color: var(--dark-gray);
  border: 2px solid #e0e0e0;
}

.nav-login-btn:hover {
  border-color: var(--orange);
  color: var(--orange);
  background: rgba(250, 154, 75, 0.05);
}

.nav-signup-btn {
  background: linear-gradient(135deg, var(--orange), var(--soft-orange));
  color: white;
  border: none;
}

.nav-signup-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(250, 154, 75, 0.3);
  color: white;
}

/* Nav Auth Buttons Group */
.nav-auth-buttons {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-left: 0.5rem;
  padding-left: 1rem;
  border-left: 1px solid #e0e0e0;
}

.logout-form {
  margin: 0;
  padding: 0;
  display: inline;
}

/* Mobile Nav Auth */
@media (max-width: 768px) {
  .nav-user {
    border-left: none;
    padding-left: 0;
    margin-left: 0;
    padding-top: 0.75rem;
    border-top: 1px solid #e0e0e0;
    width: 100%;
    justify-content: space-between;
  }
  
  .user-greeting {
    text-align: center;
    padding: 0.5rem;
    background: rgba(250, 154, 75, 0.05);
    border-radius: var(--radius-sm);
  }
  
  .btn-logout {
    width: 100%;
    justify-content: center;
  }
}
