/* ============================================
   CLOUD NOTES - PREMIUM UI STYLESHEET
   Modern, Responsive, Production-Ready Design
   ============================================ */

/* ===== CSS VARIABLES ===== */
:root {
    /* Primary Colors - Gradient Indigo/Purple */
    --primary-600: #6366f1;
    --primary-700: #4f46e5;
    --primary-800: #4338ca;
    --primary-gradient: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);

    /* Neutral Colors */
    --gray-50: #f9fafb;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --gray-800: #1f2937;
    --gray-900: #111827;

    /* Semantic Colors */
    --success: #10b981;
    --error: #ef4444;
    --warning: #f59e0b;
    --info: #3b82f6;

    /* Shadows */
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-2xl: 0 25px 50px -12px rgba(0, 0, 0, 0.25);

    /* Border Radius */
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;

    /* Transitions */
    --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-base: 250ms cubic-bezier(0.4, 0, 0.2, 1);
    --transition-slow: 350ms cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== RESET & BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--gray-800);
    background: var(--gray-50);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ===== AUTHENTICATION PAGES ===== */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    background: #2d2d2d;
    position: relative;
    overflow: hidden;
}

/* Background pattern layer */
.auth-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('notes-background.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    opacity: 0.15;
    z-index: 0;
}

/* Animated dots pattern */
.auth-container::after {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: moveBackground 20s linear infinite;
    z-index: 0;
}

@keyframes moveBackground {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(50px, 50px);
    }
}

.auth-card {
    background: white;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-2xl);
    width: 100%;
    max-width: 440px;
    padding: 2.5rem;
    position: relative;
    z-index: 1;
    animation: slideUp 0.5s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }

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

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.logo {
    display: inline-block;
    margin-bottom: 1.5rem;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-10px);
    }
}

.auth-header h1 {
    font-size: 1.875rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 0.5rem;
}

.auth-header p {
    font-size: 0.9375rem;
    color: var(--gray-500);
}

/* ===== FORMS ===== */
.auth-form {
    margin-bottom: 1.5rem;
}

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

.form-group label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 0.9375rem;
    border: 1.5px solid var(--gray-300);
    border-radius: var(--radius-md);
    transition: all var(--transition-base);
    font-family: inherit;
    background: white;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-600);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.form-hint {
    display: block;
    font-size: 0.8125rem;
    color: var(--gray-500);
    margin-top: 0.375rem;
}

.password-input {
    position: relative;
}

.password-input input {
    padding-right: 3rem;
}

.toggle-password {
    position: absolute;
    right: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--gray-400);
    cursor: pointer;
    padding: 0.5rem;
    transition: color var(--transition-fast);
}

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

.form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    font-size: 0.875rem;
    color: var(--gray-600);
    cursor: pointer;
    user-select: none;
}

.checkbox-label input[type="checkbox"] {
    width: auto;
    margin-right: 0.5rem;
    cursor: pointer;
}

.link {
    color: var(--primary-600);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: color var(--transition-fast);
}

.link:hover {
    color: var(--primary-700);
    text-decoration: underline;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 0.9375rem;
    font-weight: 600;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-base);
    font-family: inherit;
    position: relative;
    overflow: hidden;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-primary {
    background: var(--primary-gradient);
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-primary:active:not(:disabled) {
    transform: translateY(0);
}

.btn-secondary {
    background: var(--gray-100);
    color: var(--gray-700);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--gray-200);
}

.btn-danger {
    background: var(--error);
    color: white;
    box-shadow: var(--shadow-md);
}

.btn-danger:hover:not(:disabled) {
    background: #dc2626;
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-social {
    width: 100%;
    background: white;
    color: var(--gray-700);
    border: 1.5px solid var(--gray-300);
    box-shadow: var(--shadow-sm);
}

.btn-social:hover:not(:disabled) {
    background: var(--gray-50);
    border-color: var(--gray-400);
}

/* ===== 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;
}

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

.spinner-large {
    width: 48px;
    height: 48px;
    border: 4px solid var(--gray-200);
    border-top-color: var(--primary-600);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

/* ===== DIVIDER ===== */
.divider {
    position: relative;
    text-align: center;
    margin: 1.5rem 0;
}

.divider::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--gray-200);
}

.divider span {
    position: relative;
    display: inline-block;
    padding: 0 1rem;
    background: white;
    font-size: 0.875rem;
    color: var(--gray-500);
}

/* ===== SOCIAL LOGIN ===== */
.social-login {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

/* ===== AUTH FOOTER ===== */
.auth-footer {
    text-align: center;
    padding-top: 1rem;
    border-top: 1px solid var(--gray-200);
}

.auth-footer p {
    font-size: 0.875rem;
    color: var(--gray-600);
}

/* ===== OTP INPUT ===== */
.phone-input-group {
    display: flex;
    gap: 0.75rem;
    align-items: stretch;
}

.country-code {
    flex: 0 0 auto;
    width: 85px;
    min-width: 85px;
}

.country-code select {
    height: 100%;
    font-weight: 500;
    color: var(--gray-700);
    cursor: pointer;
    background-color: var(--gray-50);
    transition: all var(--transition-base);
    padding: 0.75rem 0.5rem;
    font-size: 0.875rem;
}

.country-code select:hover {
    background-color: white;
    border-color: var(--primary-600);
}

.country-code select:focus {
    background-color: white;
}

.phone-input-group input {
    flex: 1;
    min-width: 0;
    width: 100%;
}

.phone-input-group input::placeholder {
    color: var(--gray-400);
}

.otp-input-group {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    margin: 1.5rem 0;
}

.otp-input {
    width: 3rem;
    height: 3.5rem;
    text-align: center;
    font-size: 1.5rem;
    font-weight: 700;
    border: 2px solid var(--gray-300) !important;
    border-radius: var(--radius-lg) !important;
    transition: all var(--transition-fast);
    background: var(--gray-50);
}

.otp-input:focus {
    border-color: var(--primary-600) !important;
    background: white;
    transform: scale(1.08);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.otp-input:not(:placeholder-shown) {
    border-color: var(--success);
    background: white;
}

/* ===== MESSAGES ===== */
.error-message {
    padding: 0.75rem 1rem;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: var(--radius-md);
    color: var(--error);
    font-size: 0.875rem;
    margin-top: 1rem;
}

.success-message {
    padding: 0.75rem 1rem;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: var(--radius-md);
    color: var(--success);
    font-size: 0.875rem;
    margin-top: 1rem;
}

/* ===== MODAL ===== */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    background: white;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-2xl);
    max-width: 500px;
    width: 100%;
    animation: slideUp 0.3s ease-out;
}

.success-modal-content {
    padding: 2.5rem;
    text-align: center;
}

.success-icon {
    margin-bottom: 1.5rem;
}

.success-modal-content h2 {
    font-size: 1.5rem;
    color: var(--gray-900);
    margin-bottom: 0.75rem;
}

.success-modal-content p {
    color: var(--gray-600);
    margin-bottom: 1.5rem;
}

/* ===== DASHBOARD ===== */
.dashboard-body {
    background: #2d2d2d;
    min-height: 100vh;
    position: relative;
    overflow-x: hidden;
    display: flex;
    flex-direction: column;
}

/* Header */
.app-header {
    background: #2d2d2d;
    padding: 1.25rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 100;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.app-header .user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #e879f9 0%, #c084fc 100%);
    color: white;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: default;
}

.greeting-text {
    color: white;
    font-size: 1.125rem;
    font-weight: 500;
}

.menu-toggle {
    width: 40px;
    height: 40px;
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
    padding: 0.5rem;
}

.menu-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* ===== DASHBOARD MAIN ===== */
.dashboard-main {
    padding: 2rem 1.5rem;
    position: relative;
    z-index: 1;
    flex: 1;
}

.dashboard-container {
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.page-title {
    font-size: 2.5rem;
    font-weight: 700;
    color: white;
    margin-bottom: 1.5rem;
}

/* Notes Controls (Filter + View Toggle) */
.notes-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    gap: 1rem;
    flex-wrap: wrap;
}

/* Filter Buttons */
.filter-buttons {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.625rem 1.25rem;
    border: none;
    border-radius: 2rem;
    background: rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9375rem;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--transition-base);
    backdrop-filter: blur(10px);
}

.filter-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
}

.filter-btn.active {
    background: white;
    color: #2d2d2d;
}

/* View Toggle */
.view-toggle {
    display: flex;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.1);
    padding: 0.25rem;
    border-radius: 0.5rem;
    backdrop-filter: blur(10px);
}

.view-btn {
    padding: 0.5rem;
    border: none;
    border-radius: 0.375rem;
    background: transparent;
    color: rgba(255, 255, 255, 0.6);
    cursor: pointer;
    transition: all var(--transition-base);
    display: flex;
    align-items: center;
    justify-content: center;
}

.view-btn:hover {
    background: rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.9);
}

.view-btn.active {
    background: white;
    color: #4f46e5;
}

/* Floating Action Button */
.fab {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: linear-gradient(135deg, #e879f9 0%, #c084fc 100%);
    color: white;
    border: none;
    box-shadow: 0 8px 24px rgba(232, 121, 249, 0.6);
    cursor: pointer;
    transition: all var(--transition-base);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
    animation: pulse 2s ease-in-out infinite;
}

.fab:hover {
    transform: scale(1.15);
    box-shadow: 0 12px 32px rgba(232, 121, 249, 0.7);
    animation: none;
}

.fab:active {
    transform: scale(1.05);
}

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 8px 24px rgba(232, 121, 249, 0.6);
    }
    50% {
        box-shadow: 0 8px 32px rgba(232, 121, 249, 0.8);
    }
}

.dropdown-menu {
    position: fixed;
    top: 70px;
    right: 1.5rem;
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
    min-width: 240px;
    overflow: hidden;
    animation: slideDown 0.2s ease-out;
    z-index: 1000; /* Ensure dropdown appears above all content */
    cursor: default; /* Prevent pointer cursor on menu itself */
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

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

.dropdown-header {
    padding: 1rem;
    background: var(--gray-50);
}

.user-name {
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 0.25rem;
}

.user-email {
    font-size: 0.875rem;
    color: var(--gray-500);
}

.dropdown-divider {
    height: 1px;
    background: var(--gray-200);
}

.dropdown-item {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: none;
    border: none;
    font-size: 0.9375rem;
    color: var(--gray-700);
    cursor: pointer;
    transition: background var(--transition-fast);
    text-align: left;
}

.dropdown-item:hover {
    background: var(--gray-50);
}

/* ===== DASHBOARD MAIN ===== */
.dashboard-main {
    padding: 2rem 0;
    position: relative;
    z-index: 1;
    flex: 1;
}

.dashboard-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1.5rem;
    position: relative;
    z-index: 1;
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.dashboard-header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 0.25rem;
}

.notes-count {
    font-size: 0.9375rem;
    color: var(--gray-500);
}

/* ===== NOTES GRID ===== */
.notes-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.note-card {
    background: white;
    border-radius: 1rem;
    padding: 1.5rem;
    transition: all var(--transition-base);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.note-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

/* Note Card Colors */
.note-card.color-pink {
    background: linear-gradient(135deg, #fce7f3 0%, #fbcfe8 100%);
}

.note-card.color-purple {
    background: linear-gradient(135deg, #f3e8ff 0%, #e9d5ff 100%);
}

.note-card.color-blue {
    background: linear-gradient(135deg, #dbeafe 0%, #bfdbfe 100%);
}

.note-card.color-cyan {
    background: linear-gradient(135deg, #cffafe 0%, #a5f3fc 100%);
}

.note-card.color-green {
    background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
}

.note-card.color-yellow {
    background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
}

.note-card.color-orange {
    background: linear-gradient(135deg, #fed7aa 0%, #fdba74 100%);
}

.note-card.color-red {
    background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
}

.note-card.color-lavender {
    background: linear-gradient(135deg, #e0e7ff 0%, #c7d2fe 100%);
}

.note-card.color-mint {
    background: linear-gradient(135deg, #d1f4e0 0%, #a7e9c5 100%);
}

.note-card.color-peach {
    background: linear-gradient(135deg, #ffe4e6 0%, #fecdd3 100%);
}

.note-card.color-sky {
    background: linear-gradient(135deg, #e0f2fe 0%, #bae6fd 100%);
}

.note-card h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 0.75rem;
    word-break: break-word;
}

.note-content {
    color: #6b7280;
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.note-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1rem;
}

.note-date {
    font-size: 0.875rem;
    color: #9ca3af;
}

.note-card-actions {
    display: flex;
    gap: 0.5rem;
}

.note-action-btn {
    padding: 0.375rem;
    background: none;
    border: none;
    border-radius: var(--radius-sm);
    color: var(--gray-500);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.note-action-btn:hover {
    background: var(--gray-100);
    color: var(--gray-700);
}

.note-action-btn.delete:hover {
    background: #fef2f2;
    color: var(--error);
}

/* ===== EMPTY STATE ===== */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
}

.empty-state svg {
    margin-bottom: 1.5rem;
}

.empty-state h2 {
    font-size: 1.5rem;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
}

.empty-state p {
    color: var(--gray-500);
    margin-bottom: 1.5rem;
}

/* ===== LOADING STATE ===== */
.loading-state {
    text-align: center;
    padding: 4rem 2rem;
}

.loading-state p {
    color: var(--gray-500);
    margin-top: 1rem;
}

/* ===== NOTE MODAL ===== */
.note-modal-content {
    max-width: 700px;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid var(--gray-200);
}

.modal-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--gray-900);
}

.modal-close {
    padding: 0.5rem;
    background: none;
    border: none;
    color: var(--gray-400);
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
}

.modal-close:hover {
    background: var(--gray-100);
    color: var(--gray-600);
}

#note-form {
    padding: 1.5rem;
}

.note-title-input {
    font-size: 1.25rem;
    font-weight: 600;
    border: none;
    border-bottom: 2px solid var(--gray-200);
    border-radius: 0;
    padding: 0.75rem 0;
}

.note-title-input:focus {
    border-bottom-color: var(--primary-600);
    box-shadow: none;
}

.note-content-input {
    resize: vertical;
    min-height: 100px;
    border: none;
    padding: 0.75rem 0;
}

.note-content-input:focus {
    box-shadow: none;
    border: none;
}

/* Category Selection */
.category-options {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.category-checkbox {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.category-checkbox input[type="checkbox"] {
    display: none;
}

.category-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.625rem 1rem;
    border: 2px solid var(--gray-300);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-600);
    transition: all var(--transition-fast);
    background: white;
}

.category-checkbox:hover .category-label {
    border-color: var(--gray-400);
    background: var(--gray-50);
}

.category-checkbox input[type="checkbox"]:checked + .category-label {
    border-color: var(--primary-600);
    background: var(--primary-600);
    color: white;
}

.category-checkbox input[type="checkbox"]:checked + .category-label svg {
    stroke: white;
    fill: white;
}

/* Category Badges on Note Cards */
.note-categories {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    flex-wrap: wrap;
}

.category-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.25rem 0.625rem;
    border-radius: 1rem;
    font-size: 0.75rem;
    font-weight: 500;
}

.category-badge.important {
    background: rgba(239, 68, 68, 0.15);
    color: #dc2626;
}

.category-badge.important svg {
    fill: #dc2626;
    stroke: none;
}

.category-badge.bookmarked {
    background: rgba(59, 130, 246, 0.15);
    color: #2563eb;
}

.category-badge.bookmarked svg {
    fill: #2563eb;
    stroke: none;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    padding: 1.5rem;
    border-top: 1px solid var(--gray-200);
}

/* ===== DELETE MODAL ===== */
.delete-modal-content {
    max-width: 400px;
    padding: 2rem;
    text-align: center;
}

.delete-icon {
    margin-bottom: 1rem;
}

.delete-modal-content h2 {
    font-size: 1.5rem;
    color: var(--gray-900);
    margin-bottom: 0.75rem;
}

.delete-modal-content p {
    color: var(--gray-600);
    margin-bottom: 1.5rem;
}

/* ===== SHARE MODAL ===== */
.share-modal-content {
    max-width: 500px;
    padding: 0;
}

.share-content {
    padding: 2rem;
    text-align: center;
}

.share-icon {
    margin-bottom: 1rem;
}

.share-description {
    color: var(--gray-600);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
}

.share-link-container {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.share-link-input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    color: var(--gray-700);
    background-color: var(--gray-50);
    cursor: text;
}

.share-link-input:focus {
    outline: none;
    border-color: var(--primary-600);
    background-color: white;
}

.share-success-message {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem;
    background-color: #d1fae5;
    border: 1px solid #6ee7b7;
    border-radius: var(--radius-md);
    color: #065f46;
    font-size: 0.875rem;
    font-weight: 500;
}

/* ===== SHARED NOTE STYLES ===== */
.shared-note {
    position: relative;
    border: 2px solid var(--primary-600);
    max-width: 900px;
    margin: 0 auto;
}

.shared-note .note-card-header {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.shared-note .note-card-header h3 {
    word-break: break-word;
    white-space: normal;
    line-height: 1.4;
}

.shared-note .note-content {
    display: block;
    -webkit-line-clamp: unset;
    -webkit-box-orient: unset;
    overflow: visible;
    max-height: none;
    white-space: pre-wrap;
    word-wrap: break-word;
    line-height: 1.8;
    padding: 1rem 0;
}

.shared-note .note-footer {
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    padding-top: 1rem;
    margin-top: 1rem;
}

/* List View */
.notes-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.notes-list .note-card {
    max-width: 100%;
    display: flex;
    flex-direction: row;
    padding: 1.5rem;
}

.notes-list .note-card .note-card-header {
    flex: 1;
}

.notes-list .note-card .note-content {
    -webkit-line-clamp: 2;
    margin-bottom: 0.5rem;
}

.shared-badge {
    position: absolute;
    top: 1rem;
    right: 1rem;
    display: flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.5rem 1rem;
    background: var(--primary-gradient);
    color: white;
    border-radius: var(--radius-lg);
    font-size: 0.8125rem;
    font-weight: 600;
    box-shadow: var(--shadow-md);
    z-index: 10;
}

.shared-note-banner {
    background: linear-gradient(135deg, #dbeafe 0%, #e0e7ff 100%);
    border: 1px solid #93c5fd;
    border-radius: var(--radius-lg);
    padding: 1rem 1.5rem;
    margin: 0 auto 2rem;
    max-width: 900px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.banner-content {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--primary-800);
    font-size: 0.95rem;
    font-weight: 500;
}

.banner-content svg {
    flex-shrink: 0;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .auth-card {
        padding: 2rem 1.5rem;
    }

    .social-login {
        grid-template-columns: 1fr;
    }

    .notes-grid {
        grid-template-columns: 1fr;
    }

    .page-title {
        font-size: 2rem;
    }

    .filter-buttons {
        gap: 0.5rem;
    }

    .filter-btn {
        font-size: 0.875rem;
        padding: 0.5rem 1rem;
    }

    .fab {
        bottom: 1.5rem;
        right: 1.5rem;
    }

    .otp-input {
        width: 2.5rem;
        height: 2.5rem;
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .auth-card {
        padding: 1.5rem 1rem;
    }

    .auth-header h1 {
        font-size: 1.5rem;
    }

    .modal-content {
        margin: 1rem;
    }

    .app-header {
        padding: 1rem 1.25rem;
    }

    .greeting-text {
        font-size: 1rem;
    }

    .page-title {
        font-size: 1.75rem;
    }
}

/* ===== FOOTER ===== */
.app-footer {
    background: #2d2d2d;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 0.75rem 0;
    margin-top: auto;
    position: relative;
    z-index: 1;
}

.auth-footer-section {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(255, 255, 255, 0.2);
    padding: 1.5rem 0;
    margin-top: 2rem;
    position: relative;
    z-index: 1;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1.5rem;
    text-align: center;
}

.footer-content p {
    color: rgba(12, 10, 10, 0.8);
    font-size: 0.875rem;
    margin-bottom: 0.5rem;
}

.footer-content a {
    color: #a00ab7;
    text-decoration: none;
    font-weight: 500;
    transition: all var(--transition-base);
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
}

.footer-content a:hover {
    color: #7304e1;
    text-decoration: underline;
}

.footer-content a svg {
    width: 16px;
    height: 16px;
}