/* ============================================
   TEXTCRAFT NLP SKILLS - COMPONENTS
   Reusable UI Components
   Buttons, Cards, Navbar, Footer, Forms, etc.
   ============================================ */

/* ============================================
   1. NAVIGATION BAR
   ============================================ */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 1.2rem 0;
    background: rgba(253, 248, 245, 0.85);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border-bottom: 1px solid rgba(114, 47, 55, 0.1);
    z-index: 1000;
    transition: var(--transition-smooth);
}

.navbar.scrolled {
    background: rgba(253, 248, 245, 0.95);
    box-shadow: 0 4px 20px rgba(114, 47, 55, 0.1);
    border-bottom: 2px solid var(--color-gold);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Navbar Logo */
.navbar-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    font-family: 'Baskerville', serif;
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--color-burgundy);
    transition: var(--transition-smooth);
}

.navbar-brand:hover {
    transform: scale(1.02);
    color: var(--color-gold-dark);
}

.navbar-logo {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    object-fit: cover;
    border: 2px solid var(--color-gold);
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.3);
}

/* Navigation Links */
.navbar-nav {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--color-text-dark);
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    transition: var(--transition-smooth);
    position: relative;
    letter-spacing: 0.3px;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background: var(--bg-gradient-gold);
    transition: var(--transition-smooth);
}

.nav-link:hover {
    color: var(--color-burgundy);
    background: rgba(212, 175, 55, 0.1);
}

.nav-link:hover::after {
    width: 80%;
}

.nav-link.active {
    color: var(--color-burgundy);
    font-weight: 600;
}

.nav-link.active::after {
    width: 80%;
}

/* Mobile Menu Toggle */
.navbar-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.navbar-toggle span {
    display: block;
    width: 28px;
    height: 3px;
    background: var(--color-burgundy);
    border-radius: 3px;
    transition: var(--transition-smooth);
}

.navbar-toggle:hover span {
    background: var(--color-gold);
}

/* ============================================
   2. BUTTONS
   ============================================ */

.btn {
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0.875rem 2rem;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn:active {
    transform: scale(0.97);
}

/* Primary Button - Burgundy with Gold accent */
.btn-primary {
    background: var(--bg-gradient-burgundy);
    color: var(--color-text-light);
    box-shadow: var(--shadow-primary);
    border: 2px solid transparent;
}

.btn-primary:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow: var(--shadow-gold);
    border-color: var(--color-gold);
}

/* Secondary Button - Glass style */
.btn-secondary {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(10px);
    color: var(--color-burgundy);
    border: 2px solid var(--color-burgundy);
    box-shadow: var(--shadow-primary);
}

.btn-secondary:hover {
    background: rgba(114, 47, 55, 0.1);
    border-color: var(--color-gold);
    color: var(--color-burgundy);
    transform: translateY(-2px) scale(1.03);
    box-shadow: var(--shadow-hover);
}

/* Gold Button */
.btn-gold {
    background: var(--bg-gradient-gold);
    color: var(--color-text-dark);
    box-shadow: var(--shadow-gold);
    border: 2px solid transparent;
}

.btn-gold:hover {
    transform: translateY(-2px) scale(1.03);
    box-shadow: 0 12px 35px rgba(212, 175, 55, 0.5);
    border-color: var(--color-burgundy);
}

/* Button Sizes */
.btn-sm {
    padding: 0.625rem 1.25rem;
    font-size: 0.85rem;
}

.btn-lg {
    padding: 1.125rem 2.5rem;
    font-size: 1.05rem;
}

/* Icon in Button */
.btn-icon {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
}

/* ============================================
   3. CARDS
   ============================================ */

.card {
    background: var(--glass-bg);
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    padding: var(--spacing-md);
    box-shadow: var(--shadow-primary);
    transition: var(--transition-smooth);
}

.card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-hover);
    border-color: rgba(212, 175, 55, 0.3);
}

/* Card Header */
.card-header {
    padding-bottom: var(--spacing-sm);
    margin-bottom: var(--spacing-sm);
    border-bottom: 2px solid rgba(114, 47, 55, 0.1);
}

.card-title {
    font-size: 1.5rem;
    color: var(--color-burgundy);
    margin-bottom: 0.5rem;
}

.card-subtitle {
    font-size: 0.95rem;
    color: var(--color-gray);
    font-family: 'Inter', sans-serif;
}

/* Card Body */
.card-body {
    padding: var(--spacing-sm) 0;
}

/* Card Footer */
.card-footer {
    padding-top: var(--spacing-sm);
    margin-top: var(--spacing-sm);
    border-top: 1px solid rgba(114, 47, 55, 0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Luxury Card with Gold Border */
.card-luxury {
    border: 2px solid var(--color-gold);
    background: linear-gradient(135deg, rgba(253, 248, 245, 0.9), rgba(245, 237, 235, 0.9));
    box-shadow: 0 12px 35px rgba(212, 175, 55, 0.25);
}

.card-luxury:hover {
    box-shadow: 0 15px 45px rgba(212, 175, 55, 0.4);
}

/* Interactive Card (for algorithms) */
.card-interactive {
    cursor: pointer;
    position: relative;
}

.card-interactive::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border-radius: var(--radius-lg);
    background: var(--bg-gradient-gold);
    opacity: 0;
    transition: var(--transition-smooth);
    pointer-events: none;
}

.card-interactive:hover::after {
    opacity: 0.1;
}

.card-interactive.selected {
    border: 2px solid var(--color-gold);
    box-shadow: var(--shadow-gold);
}

/* ============================================
   4. FORMS & INPUTS
   ============================================ */

.form-group {
    margin-bottom: var(--spacing-md);
}

.form-label {
    display: block;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--color-burgundy);
    margin-bottom: 0.5rem;
    letter-spacing: 0.3px;
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: 0.875rem 1.25rem;
    font-family: 'Baskerville', 'Georgia', serif;
    font-size: 1rem;
    color: var(--color-text-dark);
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(10px);
    border: 2px solid rgba(114, 47, 55, 0.2);
    border-radius: var(--radius-md);
    transition: var(--transition-smooth);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    outline: none;
    border-color: var(--color-gold);
    background: rgba(255, 255, 255, 0.8);
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.1);
}

.form-textarea {
    min-height: 150px;
    resize: vertical;
    line-height: 1.6;
}

.form-input::placeholder,
.form-textarea::placeholder {
    color: var(--color-gray);
    font-style: italic;
}

/* Checkbox & Radio */
.form-check {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.form-check-input {
    width: 20px;
    height: 20px;
    border: 2px solid var(--color-burgundy);
    border-radius: 4px;
    cursor: pointer;
}

.form-check-input:checked {
    background: var(--color-gold);
    border-color: var(--color-gold);
}

.form-check-label {
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    color: var(--color-text-dark);
    cursor: pointer;
}

/* ============================================
   5. BADGES & TAGS
   ============================================ */

.badge {
    display: inline-block;
    padding: 0.375rem 0.875rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    border-radius: 20px;
    white-space: nowrap;
}

.badge-burgundy {
    background: var(--color-burgundy);
    color: var(--color-text-light);
}

.badge-gold {
    background: var(--color-gold);
    color: var(--color-text-dark);
}

.badge-outline {
    background: transparent;
    border: 2px solid var(--color-burgundy);
    color: var(--color-burgundy);
}

/* ============================================
   6. ALERTS & NOTIFICATIONS
   ============================================ */

.alert {
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-md);
    display: flex;
    align-items: center;
    gap: 1rem;
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    animation: fadeIn 0.4s ease-out;
}

.alert-success {
    background: rgba(76, 175, 80, 0.15);
    border: 2px solid #4CAF50;
    color: #2E7D32;
}

.alert-error {
    background: rgba(244, 67, 54, 0.15);
    border: 2px solid #F44336;
    color: #C62828;
}

.alert-info {
    background: rgba(212, 175, 55, 0.15);
    border: 2px solid var(--color-gold);
    color: var(--color-text-dark);
}

.alert-warning {
    background: rgba(255, 152, 0, 0.15);
    border: 2px solid #FF9800;
    color: #E65100;
}

.alert-icon {
    font-size: 1.5rem;
}

.alert-close {
    margin-left: auto;
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: inherit;
    opacity: 0.7;
    transition: var(--transition-smooth);
}

.alert-close:hover {
    opacity: 1;
}

/* ============================================
   7. MODAL / DIALOG
   ============================================ */

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(44, 24, 16, 0.7);
    backdrop-filter: blur(8px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.3s ease-out;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: var(--glass-bg);
    backdrop-filter: blur(25px);
    -webkit-backdrop-filter: blur(25px);
    border: 2px solid var(--color-gold);
    border-radius: var(--radius-xl);
    padding: var(--spacing-lg);
    max-width: 600px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(114, 47, 55, 0.3);
    animation: fadeUp 0.4s ease-out;
    position: relative;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-sm);
    border-bottom: 2px solid rgba(114, 47, 55, 0.15);
}

.modal-title {
    font-size: 2rem;
    color: var(--color-burgundy);
}

.modal-close {
    background: none;
    border: none;
    font-size: 2rem;
    color: var(--color-burgundy);
    cursor: pointer;
    transition: var(--transition-smooth);
    line-height: 1;
    padding: 0;
    width: 32px;
    height: 32px;
}

.modal-close:hover {
    color: var(--color-gold);
    transform: rotate(90deg);
}

.modal-body {
    margin-bottom: var(--spacing-md);
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 1rem;
    padding-top: var(--spacing-sm);
    border-top: 1px solid rgba(114, 47, 55, 0.1);
}

/* ============================================
   8. PROGRESS BARS
   ============================================ */

.progress {
    width: 100%;
    height: 12px;
    background: rgba(114, 47, 55, 0.1);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.progress-bar {
    height: 100%;
    background: var(--bg-gradient-gold);
    border-radius: 10px;
    transition: width 0.6s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

.progress-bar::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.4),
        transparent
    );
    animation: shimmer 2s infinite;
}

/* ============================================
   9. FOOTER
   ============================================ */

.footer {
    background: linear-gradient(180deg, #faf0e6, #f5edeb);
    border-top: 2px solid var(--color-gold);
    padding: var(--spacing-lg) 0 var(--spacing-md) 0;
    margin-top: var(--spacing-xl);
}

.footer-content {
    text-align: center;
}

.footer-text {
    font-family: 'Inter', sans-serif;
    font-size: 0.95rem;
    color: var(--color-text-dark);
    margin-bottom: var(--spacing-sm);
}

.footer-author {
    color: var(--color-burgundy);
    font-weight: 600;
}

.footer-social {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: var(--spacing-md);
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: var(--glass-bg);
    border: 2px solid var(--color-burgundy);
    color: var(--color-burgundy);
    text-decoration: none;
    font-size: 1.3rem;
    transition: var(--transition-smooth);
    box-shadow: var(--shadow-primary);
}

.social-link:hover {
    background: var(--color-burgundy);
    color: var(--color-text-light);
    transform: translateY(-4px);
    box-shadow: var(--shadow-gold);
    border-color: var(--color-gold);
}

/* ============================================
   10. TOOLTIPS
   ============================================ */

.tooltip-wrapper {
    position: relative;
    display: inline-block;
}

.tooltip {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    bottom: 125%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--color-burgundy);
    color: var(--color-text-light);
    padding: 0.5rem 1rem;
    border-radius: var(--radius-sm);
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    white-space: nowrap;
    box-shadow: var(--shadow-primary);
    transition: var(--transition-smooth);
    z-index: 100;
}

.tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--color-burgundy);
}

.tooltip-wrapper:hover .tooltip {
    visibility: visible;
    opacity: 1;
}

/* ============================================
   END OF COMPONENTS.CSS
   ============================================ */