* {
    text-decoration: none !important;
}

:root {
    --bg-color: #FFF5F9;
    --primary-color: #FF2DA5;
    /* Vibrant pink */
    --primary-hover: #e61d8f;
    --secondary-color: #741160;
    --text-color: #1A1A1A;
    --text-muted: #666666;
    --white: #ffffff;
    --card-shadow: 0 10px 40px rgba(116, 17, 96, 0.04);
    --card-border: 1px solid rgba(116, 17, 96, 0.08);
    --font-family: 'Outfit', sans-serif;
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

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

html {
    overflow-x: hidden;
}

::selection {
    background-color: var(--primary-color);
    color: var(--white);
}

body {
    font-family: var(--font-family);
    background-color: var(--white);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
    width: 100%;
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-weight: 700;
    letter-spacing: -0.02em;
}

.highlight {
    color: var(--primary-color);
}

/* Header & Navigation */
.header, .app-header {
    width: 100%;
    z-index: 100;
    background-color: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
}

.header {
    position: absolute;
}

.app-header {
    position: sticky;
    top: 0;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0;
}

.logo img {
    height: 30px;
    display: block;
}

.nav, .app-nav {
    display: flex;
    align-items: center;
    gap: 24px;
}

.app-nav a {
    text-decoration: none;
    color: var(--text-muted);
    font-weight: 500;
    transition: var(--transition);
    font-size: 15px;
}

.app-nav a:hover,
.app-nav a.active {
    color: var(--primary-color);
}

.nav-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    display: none; /* Hidden by default on desktop */
    align-items: center;
    justify-content: center;
}

.nav-toggle span {
    font-size: 24px;
    color: var(--text-color);
    line-height: 1;
}

/* Responsive navigation */
@media (max-width: 768px) {
    .app-nav a:not(.user-profile) {
        display: none;
    }

    .nav-toggle {
        display: flex;
        order: 2;
    }

    .app-nav {
        gap: 12px;
    }

    .user-profile {
        order: 1;
    }
}

.user-profile-link {
    text-decoration: none !important;
    display: flex;
    align-items: center;
}

.user-profile {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--primary-color);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    cursor: pointer;
    transition: var(--transition);
    flex-shrink: 0;
}

.user-profile:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(255, 45, 165, 0.2);
}

/* Dropdown Navigation Overlay (from UI mockup) */
.nav-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #ffffff;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transform: translateY(-100%);
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    /* slight drop shadow to separate from background */
    border-bottom-left-radius: 24px;
    border-bottom-right-radius: 24px;
    padding: 24px 0 32px 0;
}

.nav-overlay.active {
    transform: translateY(0);
}

.nav-overlay-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 5%;
    /* Align with container */
    margin-bottom: 24px;
}

.nav-overlay-header .logo img {
    height: 30px;
}

.nav-close {
    background: none;
    border: none;
    font-size: 36px;
    line-height: 1;
    color: var(--secondary-color);
    cursor: pointer;
    font-weight: 300;
    transition: transform 0.2s ease;
}

.nav-close:hover {
    color: var(--primary-color);
    transform: scale(1.1);
}

.nav-menu {
    list-style: none;
    text-align: left;
    padding: 0 5%;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.nav-menu li {
    background-color: #FFEBF4;
    /* Pale pink from mockup */
    border-radius: 6px;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease forwards;
}

.nav-overlay.active .nav-menu li {
    opacity: 1;
    transform: translateY(0);
}

.nav-menu a {
    display: block;
    padding: 16px 20px;
    text-decoration: none;
    font-size: 16px;
    font-weight: 500;
    color: var(--text-color);
    transition: background-color 0.2s;
    border-radius: 6px;
}

.nav-menu a:hover {
    background-color: #FFD6EA;
    /* slightly darker on hover */
    color: var(--primary-color);
}

/* Auth Buttons in Nav */
.nav-auth-buttons {
    display: flex;
    gap: 12px;
    padding: 0 5%;
    margin-top: 24px;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease forwards;
}

.nav-overlay.active .nav-auth-buttons {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.35s;
}

.nav-user-info {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 0 5%;
    margin-top: 24px;
    opacity: 0;
    transform: translateY(10px);
    transition: all 0.3s ease forwards;
}

.nav-overlay.active .nav-user-info {
    opacity: 1;
    transform: translateY(0);
    transition-delay: 0.35s;
}

.user-welcome {
    text-align: center;
    font-size: 16px;
    font-weight: 500;
    color: var(--text-color);
    padding: 8px 0;
}

.nav-user-info .btn-nav {
    flex: 1;
}

.btn-nav {
    flex: 1;
    text-align: center;
    padding: 16px 0;
    border-radius: 12px;
    font-size: 18px;
    font-weight: 500;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-nav.outline {
    background-color: transparent;
    border: 1px solid var(--text-color);
    color: var(--text-color);
}

.btn-nav.outline:hover {
    background-color: #f5f5f5;
}

.btn-nav.primary {
    background-color: var(--primary-color);
    border: 1px solid var(--primary-color);
    color: #ffffff;
}

.btn-nav.primary:hover {
    filter: brightness(1.1);
    box-shadow: 0 4px 15px rgba(255, 45, 165, 0.3);
}

/* Stagger effect adjustments */
.nav-overlay.active .nav-menu li:nth-child(1) {
    transition-delay: 0.1s;
}

.nav-overlay.active .nav-menu li:nth-child(2) {
    transition-delay: 0.15s;
}

.nav-overlay.active .nav-menu li:nth-child(3) {
    transition-delay: 0.2s;
}

.nav-overlay.active .nav-menu li:nth-child(4) {
    transition-delay: 0.25s;
}

.nav-overlay.active .nav-menu li:nth-child(5) {
    transition-delay: 0.3s;
}

/* Buttons */
.btn {
    padding: 14px 32px;
    border-radius: 12px;
    font-weight: 600;
    cursor: pointer;
    font-family: var(--font-family);
    font-size: 15px;
    transition: var(--transition);
    border: none;
    text-decoration: none;
    display: inline-block;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    box-shadow: 0 8px 20px rgba(255, 45, 165, 0.2);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(255, 45, 165, 0.3);
}

.btn-secondary {
    background-color: transparent;
    border: 1.5px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-secondary:hover {
    background-color: rgba(255, 45, 165, 0.05);
    transform: translateY(-3px);
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
    background-color: #999 !important;
    box-shadow: none !important;
}

.btn-primary:not(:disabled):hover {
    background-color: var(--primary-hover);
    transform: translateY(-3px);
    box-shadow: 0 12px 25px rgba(255, 45, 165, 0.3);
}

.btn.btn-primary {
    position: relative;
}

/* Sections */
section {
    padding: 120px 0;
}

.section-title {
    font-size: 38px;
    text-align: center;
    margin-bottom: 16px;
    line-height: 1.2;
}

.section-subtitle {
    text-align: center;
    color: var(--text-muted);
    max-width: 580px;
    margin: 0 auto 60px;
    font-size: 16px;
}

/* Hero Section */
.hero {
    background-color: #ffcaf46e;
    padding: 180px 0 120px;
    text-align: center;
}

.hero h1 {
    font-size: 56px;
    max-width: 800px;
    margin: 0 auto 24px;
    line-height: 1.1;
}

.hero-description {
    font-size: 17px;
    color: var(--text-muted);
    max-width: 620px;
    margin: 0 auto 40px;
}

.hero-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
}

/* Challenges Section */
.challenges {
    background-color: white;
}

.challenge-cards {
    display: flex;
    flex-direction: column;
    gap: 24px;
    max-width: 1000px;
    margin: 0 auto;
}

.challenge-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    padding: 40px;
    background: linear-gradient(90deg, #fff, #FFFDFE);
    width: 100%;
}

.challenge-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(116, 17, 96, 0.08);
    border-color: #741160;

}

.card-icon-bg {
    width: 50px;
    height: 50px;
    background-color: rgba(253, 153, 253, 0.6);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
}

.card-icon-bg img {
    height: 40px;
}

.challenge-card h3 {
    font-size: 26px;
    margin-bottom: 12px;
}

.challenge-card p {
    color: var(--text-muted);
    font-size: 16px;
}

/* How it Works */
.how-it-works {
    background-color: #FFF9FC;
}

.steps-container {
    display: flex;
    flex-direction: column;
    gap: 0;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

.steps-container::before {
    content: '';
    position: absolute;
    top: 40px;
    bottom: 40px;
    left: 45px;
    width: 2px;
    border-left: 2px dashed rgba(116, 17, 96, 0.1);
}

.step-item {
    display: flex;
    align-items: flex-start;
    gap: 40px;
    padding-bottom: 60px;
    position: relative;
    z-index: 1;
    text-align: left;
}

.step-item:last-child {
    padding-bottom: 0;
}

.step-icon-wrap {
    margin-bottom: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    flex-shrink: 0;
}

.card-step {
    width: 90px;
    height: 90px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 20px;
    margin-bottom: 12px;
    background-color: white;
    box-shadow: var(--card-shadow);
    border: var(--card-border);
}

.card-step img {
    height: 36px;
}

.step-number {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 14px;
}

.step-text {
    padding-top: 15px;
}

.step-text h3 {
    font-size: 24px;
    margin-bottom: 8px;
}

.step-text p {
    color: var(--text-muted);
    max-width: 400px;
    font-size: 15px;
}

/* Features Section */
.features-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
    max-width: 1000px;
    margin: 0 auto;
}

.feature-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 50px rgba(116, 17, 96, 0.08);
    border-color: #741160;
}

.feature-card {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 32px;
}

.feature-icon-box {
    width: 60px;
    height: 60px;
    background-color: #FFF5F9;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: var(--card-shadow);
    border: 1px solid #FFF9FC;
    background-color: #ffcaf4;
}

.feature-icon-box img {
    height: 40px;
}

.feature-content h3 {
    font-size: 22px;
    margin-bottom: 6px;
}

.feature-content p {
    font-size: 15px;
    color: var(--text-muted);
}

/* FooterStyles */
.footer {
    padding: 100px 0 40px;
    background-color: #ffcaf46e;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 60px;
    margin-bottom: 80px;
}

.footer-brand p {
    margin-top: 24px;
    color: var(--text-muted);
    max-width: 320px;
    font-size: 15px;
}

.footer-logo img {
    height: 38px;
}

.footer-links {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
}

.link-group h4 {
    margin-bottom: 24px;
    font-size: 17px;
}

.link-group ul {
    list-style: none;
}

.link-group ul li {
    margin-bottom: 14px;
}

.link-group ul li a {
    text-decoration: none;
    color: var(--text-muted);
    font-size: 15px;
    transition: var(--transition);
}

.link-group ul li a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid #f5f5f5;
    padding-top: 40px;
    text-align: center;
    color: var(--text-muted);
    font-size: 14px;
}

/* Tablet & Desktop Layouts */
@media (min-width: 768px) {
    .section-title {
        font-size: 46px;
    }

    .hero h1 {
        font-size: 72px;
    }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: 1fr 2fr;
    }

    .footer-links {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Responsive fixes */
@media (max-width: 767px) {
    section {
        padding: 80px 0;
    }

    .hero h1 {
        font-size: 40px;
    }

    .hero-actions {
        flex-direction: column;
    }

    .step-item {
        gap: 20px;
    }

    .card-step {
        width: 70px;
        height: 70px;
    }

    .steps-container::before {
        left: 35px;
    }
}

.card {
    background-color: #fff;
    border-radius: 24px;
    padding: 30px;
    box-shadow: var(--card-shadow);
    border: var(--card-border);
    transition: var(--transition);
}

/* App Header Responsive */
@media (max-width: 900px) {
    .app-nav {
        gap: 12px;
    }

    .app-nav a {
        font-size: 14px;
        padding: 8px 4px;
    }

    .user-profile {
        width: 36px;
        height: 36px;
        font-size: 14px;
    }
}

@media (max-width: 768px) {
    .app-nav a:not(:last-child) {
        display: none;
    }

    .app-nav {
        gap: 16px;
    }

    .app-nav a:last-child {
        margin-left: auto;
    }
}

/* Dashboard Responsive */
@media (max-width: 900px) {
    .dashboard-layout {
        grid-template-columns: 1fr !important;
        gap: 20px;
    }

    .stat-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .welcome-card {
        padding: 24px;
    }

    .welcome-card h1 {
        font-size: 24px;
    }

    .welcome-card p {
        font-size: 14px;
    }

    .stat-info .value {
        font-size: 20px;
    }
}

@media (max-width: 600px) {
    .stat-grid {
        grid-template-columns: 1fr;
    }
}

/* Community Responsive */
@media (max-width: 900px) {
    .community-layout {
        grid-template-columns: 1fr !important;
        gap: 20px;
    }

    .page-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .create-post {
        padding: 16px;
    }

    .post-card {
        padding: 20px;
    }
}

@media (max-width: 600px) {
    .post-actions {
        flex-wrap: wrap;
        gap: 12px;
    }

    .action-btn {
        font-size: 13px;
    }
}

/* Activities Responsive */
@media (max-width: 900px) {
    .activities-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }

    .activity-card {
        padding: 20px;
    }

    .activity-card h3 {
        font-size: 18px;
    }
}

@media (max-width: 600px) {
    .activities-grid {
        grid-template-columns: 1fr;
    }

    .filter-bar {
        flex-wrap: wrap;
    }

    .filter-btn {
        flex: 1 1 auto;
        min-width: calc(50% - 6px);
        text-align: center;
    }
}

/* Survey Responsive */
@media (max-width: 900px) {
    .options-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 600px) {
    .options-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .question-text {
        font-size: 16px;
    }

    .survey-card {
        padding: 24px;
    }

    .question-group {
        margin-bottom: 24px;
        padding-bottom: 24px;
    }

    .action-bar {
        flex-direction: column;
    }

    .action-bar .btn {
        width: 100%;
        text-align: center;
    }
}

/* General Mobile Optimizations */
@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }

    .section-title {
        font-size: 28px;
    }

    .section-subtitle {
        font-size: 15px;
        padding: 0 16px;
    }

    .app-header {
        padding: 16px 0;
    }

    .login-prompt {
        padding: 60px 16px;
    }

    .login-prompt h2 {
        font-size: 24px;
    }

    .page-header h1 {
        font-size: 28px;
    }

    .hero h1 {
        font-size: 36px;
    }

    .hero-description {
        font-size: 16px;
    }

    .hero-actions {
        flex-direction: column;
        gap: 16px;
    }

    .hero-actions .btn {
        width: 100%;
        text-align: center;
    }

    .challenge-card {
        padding: 24px;
    }

    .challenge-card h3 {
        font-size: 22px;
    }

    .card-step {
        width: 70px;
        height: 70px;
    }

    .step-text h3 {
        font-size: 20px;
    }
}

@media (max-width: 600px) {
    .section-title {
        font-size: 24px;
    }

    .hero h1 {
        font-size: 28px;
        line-height: 1.2;
    }

    .hero-description {
        font-size: 15px;
    }

    .widget {
        padding: 20px;
    }

    .activity-list {
        gap: 12px;
    }

    .activity-item {
        padding: 16px;
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .activity-item .btn {
        width: 100%;
        text-align: center;
    }

    .footer-links {
        grid-template-columns: 1fr;
    }

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

/* Tablet specific */
@media (min-width: 601px) and (max-width: 900px) {
    .hero h1 {
        font-size: 48px;
    }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-width: 360px;
}

.toast {
    background: white;
    border-radius: 12px;
    padding: 16px 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    display: flex;
    align-items: flex-start;
    gap: 12px;
    animation: slideInRight 0.3s ease forwards;
    border-left: 4px solid var(--primary-color);
}

.toast.success {
    border-left-color: #4caf50;
}

.toast.error {
    border-left-color: #f44336;
}

.toast.warning {
    border-left-color: #ff9800;
}

.toast.info {
    border-left-color: #2196f3;
}

.toast-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.toast-content {
    flex-grow: 1;
}

.toast-title {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 4px;
    color: var(--text-color);
}

.toast-message {
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.4;
}

.toast-close {
    background: none;
    border: none;
    font-size: 18px;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: color 0.2s;
}

.toast-close:hover {
    color: var(--text-color);
}

.toast.fade-out {
    animation: slideOutRight 0.3s ease forwards;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideOutRight {
    from {
        transform: translateX(0);
        opacity: 1;
    }

    to {
        transform: translateX(100%);
        opacity: 0;
    }
}

/* Accessibility Focus States */
*:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Skip Link */
.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-color);
    color: white;
    padding: 8px 16px;
    z-index: 10000;
    transition: top 0.3s;
}

.skip-link:focus {
    top: 0;
}

/* Loading Spinner */
.spinner {
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    display: inline-block;
    vertical-align: middle;
    margin-right: 8px;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Form Validation Styles */
.form-control.error {
    border-color: #f44336;
    background: #fff5f5;
}

.form-control.success {
    border-color: #4caf50;
}

.error-message {
    color: #f44336;
    font-size: 12px;
    margin-top: 6px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.error-message::before {
    content: '⚠';
    font-size: 12px;
}

/* Touch-friendly improvements for mobile */
@media (max-width: 768px) {

    /* Larger touch targets */
    .btn {
        padding: 16px 24px;
        min-height: 48px;
    }

    .filter-btn {
        min-height: 44px;
    }

    .nav-item {
        min-height: 48px;
    }

    /* Better spacing for touch */
    .form-control,
    input[type="text"],
    input[type="email"],
    input[type="password"] {
        min-height: 48px;
        font-size: 16px;
        /* Prevents zoom on iOS */
    }

    /* Card hover effects disabled on touch */
    .card:hover,
    .activity-card:hover,
    .challenge-card:hover,
    .feature-card:hover {
        transform: none;
    }

    /* Scrollable areas */
    .filter-bar {
        -webkit-overflow-scrolling: touch;
    }
}