/* Modern Responsive CSS for Mywroom Forms */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@300;400;500;600;700;800&family=Outfit:wght@400;500;600;700;800;900&family=Poppins:wght@400;500;600;700;800&display=swap');

:root {
    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --primary-light: #eef2ff;
    --secondary: #06b6d4;
    --accent: #f59e0b;
    --success: #10b981;
    --success-bg: #ecfdf5;
    --danger: #ef4444;
    --danger-bg: #fef2f2;
    --dark: #0f172a;
    --dark-muted: #475569;
    --light-bg: #f8fafc;
    --card-bg: #ffffff;
    --border: #e2e8f0;
    --border-focus: #818cf8;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 25px -3px rgb(0 0 0 / 0.08), 0 4px 6px -4px rgb(0 0 0 / 0.04);
    --shadow-xl: 0 20px 35px -5px rgb(0 0 0 / 0.12), 0 8px 10px -6px rgb(0 0 0 / 0.06);
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-full: 9999px;
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

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

body {
    font-family: 'Poppins', 'Plus Jakarta Sans', sans-serif;
    background: linear-gradient(135deg, #f0f4ff 0%, #faf5ff 50%, #f0fdf4 100%);
    min-height: 100vh;
    color: var(--dark);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
}

/* Header & Nav */
.header {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0.75rem 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: var(--dark);
    font-family: 'Poppins', sans-serif;
    font-weight: 700;
    font-size: 1.35rem;
}

.brand-icon {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 10px rgba(79, 70, 229, 0.3);
    overflow: hidden;
}

.brand-logo-img {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: cover;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
    display: block;
}

.hero-logo-img {
    width: 80px;
    height: 80px;
    border-radius: 16px;
    object-fit: cover;
    margin: 0 auto 1rem;
    box-shadow: 0 8px 24px rgba(79, 70, 229, 0.2);
    border: 3px solid white;
}

.nav-links {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    list-style: none;
    background: #f1f5f9;
    padding: 4px;
    border-radius: var(--radius-full);
    border: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.05);
    max-width: 420px;
    width: 100%;
}

.nav-links li {
    flex: 1;
}

.nav-link {
    text-decoration: none;
    color: var(--dark-muted);
    font-weight: 600;
    font-size: 0.88rem;
    padding: 0.55rem 0.85rem;
    border-radius: var(--radius-full);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    width: 100%;
    text-align: center;
    white-space: nowrap;
}

.nav-link:hover {
    color: var(--primary);
    background: rgba(255, 255, 255, 0.7);
}

.nav-link.active {
    color: white;
    background: var(--primary);
    box-shadow: 0 3px 10px rgba(79, 70, 229, 0.28);
}

/* Main Container */
.main-wrapper {
    flex: 1;
    max-width: 1100px;
    margin: 2rem auto;
    padding: 0 1.5rem;
    width: 100%;
}

/* Hero Section for Index */
.hero-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2.5rem 2rem;
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
}

.hero-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 6px;
    background: linear-gradient(90deg, var(--primary), var(--secondary), var(--accent));
}

.hero-header-flex {
    display: flex;
    align-items: center;
    gap: 1.75rem;
    text-align: left;
    margin-bottom: 1.75rem;
    padding-bottom: 1.75rem;
    border-bottom: 1px solid var(--border);
}

.hero-header-flex .hero-logo-img {
    margin: 0;
    width: 100px;
    height: 100px;
    border-radius: 20px;
    flex-shrink: 0;
    box-shadow: 0 10px 25px rgba(79, 70, 229, 0.2);
}

.hero-header-content {
    flex: 1;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.35rem 0.9rem;
    background: var(--primary-light);
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 700;
    border-radius: var(--radius-full);
    margin-bottom: 0.6rem;
}

.hero-title {
    font-family: 'Poppins', 'Outfit', sans-serif;
    font-size: 2.25rem;
    font-weight: 700;
    color: var(--dark);
    line-height: 1.2;
    margin-bottom: 0.5rem;
}

.hero-title span {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.hero-subtitle {
    color: var(--dark-muted);
    font-size: 1.05rem;
    margin: 0;
}

/* Grid Cards */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.feature-card {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2rem;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    position: relative;
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
    border-color: var(--border-focus);
}

.feature-icon-wrapper {
    width: 56px;
    height: 56px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.75rem;
    margin-bottom: 1.25rem;
}

.icon-blue {
    background: #eff6ff;
    color: #2563eb;
}

.icon-purple {
    background: #faf5ff;
    color: #9333ea;
}

.feature-card h3 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: var(--dark);
}

.feature-card p {
    color: var(--dark-muted);
    font-size: 0.95rem;
    flex: 1;
    margin-bottom: 1.5rem;
}

.feature-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 0.95rem;
    color: var(--primary);
    transition: var(--transition);
}

.feature-card:hover .feature-btn {
    gap: 0.75rem;
}

/* Forms Card Layout */
.form-container {
    max-width: 680px;
    margin: 0 auto;
}

.form-card {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--border);
    overflow: hidden;
}

.form-card-header {
    background: linear-gradient(135deg, #4f46e5, #6366f1);
    color: white;
    padding: 1.15rem 1.5rem;
    position: relative;
}

.form-card-header-flex {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 1rem;
    text-align: left;
}

.form-header-logo {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    object-fit: cover;
    border: 2px solid rgba(255, 255, 255, 0.9);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    flex-shrink: 0;
}

.form-header-text {
    flex: 1;
}

.form-header-text h2 {
    font-family: 'Poppins', sans-serif;
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 0.15rem;
    line-height: 1.25;
}

.form-header-text p {
    font-size: 0.85rem;
    opacity: 0.92;
    margin: 0;
    font-weight: 400;
    line-height: 1.3;
}

.form-body {
    padding: 2rem;
}

/* Form Groups & Inputs */
.form-group {
    margin-bottom: 1.35rem;
}

.form-label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--dark);
    margin-bottom: 0.4rem;
}

.form-label .required {
    color: var(--danger);
    margin-left: 2px;
}

.input-with-icon {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 1rem;
    color: #94a3b8;
    display: flex;
    align-items: center;
    pointer-events: none;
}

.form-control {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.975rem;
    font-family: inherit;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-md);
    background-color: #fff;
    color: var(--dark);
    transition: var(--transition);
}

.input-with-icon .form-control {
    padding-left: 2.75rem;
}

.form-control:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.15);
}

select.form-control {
    cursor: pointer;
}

textarea.form-control {
    resize: vertical;
    min-height: 95px;
}

.input-hint {
    font-size: 0.8rem;
    color: var(--dark-muted);
    margin-top: 0.3rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.85rem 1.75rem;
    font-size: 1rem;
    font-weight: 700;
    font-family: inherit;
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    width: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), #6366f1);
    color: white;
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--primary-hover), var(--primary));
    box-shadow: 0 6px 20px rgba(79, 70, 229, 0.4);
    transform: translateY(-1px);
}

.btn-secondary {
    background: #f1f5f9;
    color: var(--dark);
}

.btn-secondary:hover {
    background: #e2e8f0;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* Search Box Component for Feedback Lookup */
.lookup-box {
    background: var(--light-bg);
    border: 2px dashed #cbd5e1;
    border-radius: var(--radius-md);
    padding: 1.5rem;
    margin-bottom: 1.75rem;
}

.lookup-flex {
    display: flex;
    gap: 0.75rem;
}

.lookup-flex .form-control {
    flex: 1;
}

.lookup-btn {
    width: auto;
    padding: 0 1.5rem;
    white-space: nowrap;
}

/* Member Details Profile Card (Shown upon Mobile Lookup) */
.member-profile-card {
    background: linear-gradient(135deg, #f8fafc 0%, #eef2ff 100%);
    border: 1.5px solid #c7d2fe;
    border-radius: var(--radius-md);
    padding: 1.25rem;
    margin-bottom: 1.75rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    animation: fadeIn 0.3s ease-out;
}

.member-profile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid #e0e7ff;
    padding-bottom: 0.75rem;
}

.member-profile-header .badge {
    background: var(--success-bg);
    color: var(--success);
    font-size: 0.75rem;
    font-weight: 700;
    padding: 0.25rem 0.6rem;
    border-radius: var(--radius-full);
    border: 1px solid #a7f3d0;
}

.member-profile-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    gap: 1rem;
}

.profile-field-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: #64748b;
}

.profile-field-value {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--dark);
}

/* Connect Question (Yes/No Pill Radio) */
.connect-question-box {
    background: #faf5ff;
    border: 1.5px solid #e9d5ff;
    border-radius: var(--radius-md);
    padding: 1.25rem;
    margin-bottom: 1.5rem;
}

.connect-options-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-top: 0.75rem;
}

.connect-pill {
    position: relative;
}

.connect-pill input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.connect-pill-label {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.85rem 1rem;
    border: 2px solid var(--border);
    background: white;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
}

.connect-pill input[type="radio"]:checked + .connect-pill-label.pill-yes {
    background: #ecfdf5;
    border-color: var(--success);
    color: #065f46;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

.connect-pill input[type="radio"]:checked + .connect-pill-label.pill-no {
    background: #fef2f2;
    border-color: var(--danger);
    color: #991b1b;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.15);
}

/* Rating Stars / Chips */
.rating-group {
    display: flex;
    gap: 0.5rem;
    margin-top: 0.4rem;
}

.rating-chip {
    flex: 1;
    position: relative;
}

.rating-chip input {
    position: absolute;
    opacity: 0;
}

.rating-chip label {
    display: block;
    text-align: center;
    padding: 0.6rem 0.25rem;
    background: #f8fafc;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    transition: var(--transition);
}

.rating-chip input:checked + label {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

/* Alerts and Toast */
.alert {
    padding: 0.55rem 0.9rem;
    border-radius: 8px;
    margin-bottom: 0.85rem;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    gap: 0.55rem;
    animation: fadeIn 0.3s ease-out;
}

.alert-success {
    background-color: var(--success-bg);
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.alert-danger {
    background-color: var(--danger-bg);
    color: #991b1b;
    border: 1px solid #fecaca;
}

.alert-info {
    background-color: #eff6ff;
    color: #1e40af;
    border: 1px solid #bfdbfe;
}

/* Loading Spinner */
.spinner {
    display: inline-block;
    width: 18px;
    height: 18px;
    border: 2.5px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 0.7s linear infinite;
}

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

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-6px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Success Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    padding: 1rem;
}

.modal-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.modal-content {
    background: white;
    border-radius: var(--radius-lg);
    padding: 2.5rem 2rem;
    max-width: 480px;
    width: 100%;
    text-align: center;
    box-shadow: var(--shadow-xl);
    transform: scale(0.9);
    transition: transform 0.3s ease;
}

.modal-overlay.active .modal-content {
    transform: scale(1);
}

.success-icon-circle {
    width: 72px;
    height: 72px;
    background: #d1fae5;
    color: #10b981;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.2rem;
    margin: 0 auto 1.25rem;
}

/* Footer */
.footer {
    text-align: center;
    padding: 2rem 1.5rem;
    color: #94a3b8;
    font-size: 0.85rem;
    margin-top: auto;
}

/* Responsive */
@media (max-width: 640px) {
    .main-wrapper {
        margin: 1rem auto;
        padding: 0 0.85rem;
    }

    .hero-header-flex {
        flex-direction: column;
        text-align: center;
        gap: 0.85rem;
    }

    .hero-header-flex .hero-logo-img {
        margin: 0 auto;
        width: 80px;
        height: 80px;
    }

    .form-card {
        border-radius: var(--radius-md);
    }

    .form-card-header {
        padding: 0.85rem 1.15rem;
    }

    .form-card-header-flex {
        flex-direction: row;
        text-align: left;
        gap: 0.75rem;
        align-items: center;
    }

    .form-header-logo {
        width: 44px;
        height: 44px;
        border-radius: 10px;
        margin: 0;
        flex-shrink: 0;
    }

    .form-header-text h2 {
        font-size: 1.15rem;
        margin-bottom: 0.1rem;
    }

    .form-header-text p {
        font-size: 0.78rem;
        line-height: 1.25;
    }

    .form-body {
        padding: 1.25rem 1rem;
    }

    .form-group {
        margin-bottom: 1.15rem;
    }

    .form-label {
        font-size: 0.88rem;
        margin-bottom: 0.35rem;
    }

    .form-control {
        padding: 0.65rem 0.85rem;
        font-size: 0.92rem;
    }

    .input-with-icon .form-control {
        padding-left: 2.5rem;
    }

    .input-icon {
        left: 0.85rem;
    }

    /* Feedback Specific Mobile Styles */
    .lookup-box {
        padding: 1rem 0.85rem;
        margin-bottom: 1.25rem;
        border-radius: 10px;
    }

    .lookup-flex {
        display: flex;
        flex-direction: column;
        gap: 0.6rem;
    }

    .lookup-btn {
        width: 100%;
        padding: 0.65rem 1rem;
        font-size: 0.92rem;
    }

    .member-profile-card {
        padding: 1rem;
        margin-bottom: 1.25rem;
        border-radius: 10px;
        gap: 0.6rem;
    }

    .member-profile-header {
        padding-bottom: 0.6rem;
    }

    .member-profile-header h4 {
        font-size: 1.1rem !important;
    }

    .member-profile-grid {
        grid-template-columns: 1fr;
        gap: 0.6rem;
    }

    .profile-field-label {
        font-size: 0.72rem;
    }

    .profile-field-value {
        font-size: 0.9rem;
    }

    .rating-group {
        gap: 0.35rem;
    }

    .rating-chip label {
        padding: 0.5rem 0.2rem;
        font-size: 0.78rem;
        border-radius: 8px;
    }

    .connect-question-box {
        padding: 1rem 0.85rem;
        margin-bottom: 1.25rem;
        border-radius: 10px;
    }

    .connect-options-grid {
        gap: 0.6rem;
    }

    .connect-pill-label {
        padding: 0.7rem 0.5rem;
        font-size: 0.9rem;
        gap: 0.4rem;
        border-radius: 10px;
    }

    .btn {
        padding: 0.75rem 1.25rem;
        font-size: 0.95rem;
    }

    .hero-title {
        font-size: 1.6rem;
    }
}

@media (max-width: 420px) {
    .nav-links {
        max-width: 100%;
        padding: 3px;
    }
    .nav-link {
        font-size: 0.8rem;
        padding: 0.45rem 0.45rem;
        gap: 0.25rem;
    }
    .connect-pill-label {
        font-size: 0.82rem;
        padding: 0.65rem 0.35rem;
    }
}
