/* Notes Page Styles */

/* Override main-content padding for notes page */
body .main-content {
    padding: 3rem 0;
    margin-top: 0;
}

/* Remove container top padding on notes page */
body .main-content .container {
    padding-top: 0;
}

/* Notes Hero Section */
.notes-hero {
    position: relative;
    background: linear-gradient(135deg, rgba(71, 101, 233, 0.559) 0%, rgba(51, 122, 215, 0.691) 100%), 
                url('../img/ai.webp') center/cover no-repeat;
    color: white;
    padding: 6rem 0 5rem;
    overflow: hidden;
}

.notes-hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    overflow: hidden;
    pointer-events: none;
}

.notes-hero-pattern {
    position: absolute;
    width: 100%;
    height: 100%;
    background-image: 
        radial-gradient(circle at 20% 50%, rgba(255, 255, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    animation: notesFloat 20s ease-in-out infinite;
}

@keyframes notesFloat {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-20px); }
}

.notes-hero-content {
    position: relative;
    z-index: 10;
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.notes-hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.25rem;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 50px;
    font-size: 0.875rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.notes-hero-title {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 1.5rem;
    letter-spacing: -0.02em;
}

.notes-hero-subtitle {
    font-size: 1.25rem;
    line-height: 1.7;
    margin-bottom: 2.5rem;
    opacity: 0.95;
}

.notes-hero-features {
    display: flex;
    gap: 2rem;
    justify-content: center;
    flex-wrap: wrap;
}

.notes-feature-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: 50px;
    font-weight: 500;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.notes-feature-item svg {
    flex-shrink: 0;
}

/* Selection Section */
.notes-selection {
    position: relative;
    margin-bottom: 3rem;
}

.selection-card {
    background: white;
    border-radius: 16px;
    padding: 2.5rem;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid #e5e7eb;
    transition: all 0.3s ease;
}

.selection-card:hover {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.selection-card h2 {
    margin: 0 0 0.5rem 0;
    color: var(--text-dark);
    font-size: 1.75rem;
    font-weight: 700;
}

.selection-description {
    color: var(--text-medium);
    margin: 0 0 2rem 0;
    font-size: 1rem;
}

.selection-form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 0.9rem;
}

.form-select {
    padding: 0.875rem 1rem;
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-size: 1rem;
    background: white;
    transition: all 0.2s;
    cursor: pointer;
    width: 100%;
    box-sizing: border-box;
    max-width: 100%;
}

.form-select:hover:not(:disabled) {
    border-color: var(--primary-color);
    background: #f9fafb;
}

.form-select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
    background: white;
}

.form-select:disabled {
    background: #f9fafb;
    cursor: not-allowed;
    opacity: 0.6;
}

.btn-generate {
    grid-column: 1 / -1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1.125rem 2.5rem;
    background: #2563eb !important;
    color: white !important;
    border: none;
    border-radius: 12px;
    font-size: 1.125rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(37, 99, 235, 0.3);
    margin-top: 0.5rem;
}

.btn-generate:hover:not(:disabled) {
    background: #1d4ed8 !important;
    color: white !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(37, 99, 235, 0.4);
}

.btn-generate:active:not(:disabled) {
    transform: translateY(0);
}

.btn-generate:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    background: #2563eb !important;
}

/* Premium Lock Overlay */
.premium-lock-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(12px);
    display: none;
    align-items: center;
    justify-content: center;
    border-radius: 16px;
    z-index: 10;
}

.premium-lock-overlay.active {
    display: flex;
}

.premium-lock-content {
    text-align: center;
    max-width: 450px;
    padding: 2.5rem;
    background: white;
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
}

.lock-icon {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    animation: lockPulse 2s ease-in-out infinite;
}

@keyframes lockPulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

.premium-lock-content h3 {
    margin: 0 0 1rem 0;
    color: var(--text-dark);
    font-size: 1.75rem;
    font-weight: 700;
}

.premium-lock-content p {
    color: var(--text-medium);
    margin: 0 0 2rem 0;
    font-size: 1rem;
    line-height: 1.6;
}

.btn-upgrade {
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem 2rem;
    background: #2563eb !important;
    color: #ffffff !important;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1.125rem;
    transition: all 0.18s ease;
    box-shadow: 0 6px 20px rgba(37, 99, 235, 0.18);
    border: 1px solid rgba(37, 99, 235, 0.12);
}

.btn-upgrade:hover {
    transform: translateY(-2px);
    background: #1d4ed8 !important;
    color: #fff !important;
    box-shadow: 0 8px 30px rgba(37, 99, 235, 0.25);
}

/* Loading State */
.notes-loading {
    background: white;
    border-radius: 16px;
    padding: 4rem 2rem;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid #e5e7eb;
}

.loading-content h3 {
    margin: 1rem 0 0.5rem 0;
    color: var(--text-dark);
    font-size: 1.5rem;
}

.loading-content p {
    color: var(--text-medium);
    margin: 0 0 2rem 0;
}

.loading-steps {
    display: flex;
    justify-content: center;
    gap: 2rem;
    max-width: 600px;
    margin: 0 auto;
}

.loading-step {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    opacity: 0.4;
    transition: opacity 0.3s;
}

.loading-step.active {
    opacity: 1;
}

.step-number {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    background: #e5e7eb;
    border-radius: 50%;
    font-weight: 700;
    font-size: 0.875rem;
    color: var(--text-medium);
}

.loading-step.active .step-number {
    background: var(--primary-color);
    color: white;
}

.step-text {
    font-size: 0.875rem;
    color: var(--text-dark);
}

/* Notes Display */
.notes-display {
    animation: fadeIn 0.3s;
}

.notes-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    background: white;
    color: var(--text-dark);
    border: 2px solid #e5e7eb;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-secondary:hover {
    background: #f9fafb;
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.notes-actions {
    display: flex;
    gap: 0.75rem;
}

.btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: white;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-icon:hover {
    background: #f9fafb;
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.notes-content-wrapper {
    display: grid;
    grid-template-columns: 250px 1fr;
    gap: 2rem;
    align-items: start;
}

/* Table of Contents */
.notes-toc {
    position: sticky;
    top: 2rem;
    background: white;
    border-radius: 16px;
    padding: 1.75rem;
    border: 2px solid #e5e7eb;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.notes-toc h3 {
    margin: 0 0 1.25rem 0;
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--text-dark);
}

#tocNav {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.toc-link {
    display: block;
    padding: 0.625rem 0.75rem;
    color: var(--text-medium);
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.toc-link:hover {
    background: rgba(102, 126, 234, 0.08);
    color: var(--primary-color);
    padding-left: 1rem;
}

.toc-link.active {
    background: rgba(102, 126, 234, 0.1);
    color: var(--primary-color);
    font-weight: 600;
}

/* Notes Content */
.notes-content {
    background: white;
    border-radius: 16px;
    padding: 3rem;
    border: 2px solid #e5e7eb;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    line-height: 1.8;
}

.notes-meta {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1.25rem 1.5rem;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.08) 0%, rgba(118, 75, 162, 0.08) 100%);
    border-radius: 12px;
    border: 1px solid rgba(102, 126, 234, 0.2);
    margin-bottom: 2rem;
    font-size: 0.875rem;
    color: var(--text-medium);
}

.notes-meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.notes-content h1 {
    font-size: 2rem;
    color: var(--text-dark);
    margin: 0 0 1.5rem 0;
    padding-bottom: 1rem;
    border-bottom: 2px solid #e5e7eb;
}

.notes-content h2 {
    font-size: 1.5rem;
    color: var(--text-dark);
    margin: 2rem 0 1rem 0;
    scroll-margin-top: 2rem;
}

.notes-content h3 {
    font-size: 1.25rem;
    color: var(--text-dark);
    margin: 1.5rem 0 0.75rem 0;
}

.notes-content p {
    margin: 0 0 1rem 0;
    color: var(--text-medium);
}

.notes-content ul,
.notes-content ol {
    margin: 0 0 1rem 0;
    padding-left: 1.5rem;
    color: var(--text-medium);
}

.notes-content li {
    margin-bottom: 0.5rem;
}

.notes-content strong {
    color: var(--text-dark);
    font-weight: 600;
}

/* Formula Box */
.formula-box {
    background: #f9fafb;
    border-left: 4px solid var(--primary-color);
    padding: 1rem 1.25rem;
    margin: 1rem 0;
    border-radius: 6px;
    font-family: 'Courier New', monospace;
    font-size: 0.95rem;
}

/* Key Point */
.key-point {
    background: rgba(102, 126, 234, 0.05);
    border-left: 4px solid var(--primary-color);
    padding: 1rem 1.25rem;
    margin: 1rem 0;
    border-radius: 6px;
}

.key-point-title {
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Example Box */
.example-box {
    background: #fffbeb;
    border: 1px solid #fcd34d;
    padding: 1rem 1.25rem;
    margin: 1rem 0;
    border-radius: 6px;
}

.example-title {
    font-weight: 700;
    color: #92400e;
    margin-bottom: 0.5rem;
}

/* Print Styles */
@media print {
    .site-header,
    .site-footer,
    .notes-controls,
    .notes-toc,
    .cookie-consent {
        display: none !important;
    }

    .notes-content-wrapper {
        grid-template-columns: 1fr;
    }

    .notes-content {
        box-shadow: none;
        border: none;
    }
}

/* Responsive */
@media (max-width: 968px) {
    .notes-content-wrapper {
        grid-template-columns: 1fr;
    }

    .notes-toc {
        position: static;
        order: -1;
    }

    .loading-steps {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .notes-hero {
        padding: 4rem 0 3rem;
    }

    .notes-hero-title {
        font-size: 2.25rem;
    }

    .notes-hero-subtitle {
        font-size: 1.125rem;
    }

    .notes-hero-features {
        gap: 1rem;
    }
}

@media (max-width: 640px) {
    .notes-hero {
        padding: 3rem 0 2.5rem;
    }

    .notes-hero-title {
        font-size: 1.875rem;
    }

    .notes-hero-subtitle {
        font-size: 1rem;
        margin-bottom: 2rem;
    }

    .notes-hero-features {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }

    .notes-feature-item {
        justify-content: center;
    }

    .selection-card {
        padding: 1.5rem;
    }

    .selection-card h2 {
        font-size: 1.5rem;
    }

    .selection-form {
        grid-template-columns: 1fr;
    }

    .btn-generate {
        padding: 1rem 2rem;
        font-size: 1rem;
    }

    .notes-content {
        padding: 1.5rem;
    }

    .notes-content h1 {
        font-size: 1.5rem;
    }

    .notes-content h2 {
        font-size: 1.25rem;
    }
}

/* Spinner */
.spinner-large {
    width: 60px;
    height: 60px;
    border: 4px solid #f3f4f6;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
