@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Plus+Jakarta+Sans:wght@500;600;700;800&display=swap');

:root {
    --primary: #1e40af;
    --primary-hover: #1d4ed8;
    --primary-light: #eff6ff;
    --primary-border: #bfdbfe;
    --accent: #2563eb;
    
    --bg-main: #f8fafc;
    --card-bg: #ffffff;
    --text-primary: #0f172a;
    --text-secondary: #334155;
    --text-muted: #64748b;
    
    --border-light: #e2e8f0;
    --shadow-subtle: 0 1px 3px rgba(15, 23, 42, 0.04), 0 1px 2px rgba(15, 23, 42, 0.02);
    --shadow-card: 0 4px 6px -1px rgba(15, 23, 42, 0.05), 0 2px 4px -2px rgba(15, 23, 42, 0.03);
    --shadow-hover: 0 12px 20px -3px rgba(15, 23, 42, 0.08), 0 4px 6px -4px rgba(15, 23, 42, 0.03);
    
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-full: 9999px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    -webkit-tap-highlight-color: transparent;
}

body {
    background: var(--bg-main);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    overflow-x: hidden;
}

header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 0.85rem 1.5rem;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow-subtle);
    border-bottom: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.header-container img {
    height: 2.5rem;
    width: auto;
}

header h1 {
    font-family: 'Plus Jakarta Sans', 'Inter', sans-serif;
    font-size: 1.8rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text-primary);
}

.container {
    width: 92%;
    max-width: 1040px;
    margin: 36px auto;
    background: #ffffff;
    border-radius: var(--radius-lg);
    padding: 36px;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-card);
    animation: fadeIn 0.6s ease-in;
}

.section {
    margin-bottom: 32px;
    padding: 28px;
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-light);
    transition: transform 0.2s ease, border-color 0.2s ease;
}

.section:hover {
    transform: translateY(-2px);
    border-color: #cbd5e1;
}

.section h2 {
    font-family: 'Plus Jakarta Sans', 'Inter', sans-serif;
    font-size: 1.45rem;
    color: var(--text-primary);
    margin-bottom: 14px;
    border-bottom: 2px solid var(--border-light);
    padding-bottom: 10px;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.section p {
    font-size: 1rem;
    color: var(--text-secondary);
    text-align: justify;
    line-height: 1.7;
}

.search-container {
    position: relative;
    width: 100%;
    max-width: 640px;
    margin: 0 auto 32px;
    display: flex;
    align-items: center;
}

#search-bar {
    width: 100%;
    padding: 14px 48px 14px 22px;
    font-size: 0.98rem;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-full);
    background: #f1f5f9;
    color: var(--text-primary);
    box-shadow: inset 0 1px 2px rgba(15, 23, 42, 0.03);
    transition: all 0.2s ease;
}

#search-bar:focus {
    outline: none;
    background: #ffffff;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.12);
}

#search-bar::placeholder {
    color: var(--text-muted);
}

#clear-button {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: #ef4444;
    color: #fff;
    border: none;
    border-radius: var(--radius-full);
    width: 26px;
    height: 26px;
    font-size: 0.95rem;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

#clear-button:hover {
    background: #dc2626;
    transform: translateY(-50%) scale(1.08);
}

#suggestions-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #ffffff;
    border-radius: var(--radius-md);
    max-height: 320px;
    overflow-y: auto;
    color: var(--text-primary);
    box-shadow: var(--shadow-hover);
    display: none;
    z-index: 1000;
    padding: 8px;
    border: 1px solid var(--border-light);
    margin-top: 8px;
}

.suggestion-item {
    padding: 4px;
    border-radius: var(--radius-sm);
    transition: background 0.2s ease;
}

.suggestion-item.highlight {
    border-left: 3px solid var(--primary);
}

.suggestion-button {
    display: block;
    width: 100%;
    padding: 10px 14px;
    font-size: 0.92rem;
    background: transparent;
    color: var(--text-primary);
    border: none;
    border-radius: var(--radius-sm);
    text-align: left;
    cursor: pointer;
    transition: all 0.2s ease;
}

.suggestion-button:hover, .suggestion-button.focused {
    background: var(--primary-light);
    color: var(--primary);
    transform: translateX(4px);
}

/* Primary Action CTA Button */
.explore-button {
    background: var(--primary);
    color: #ffffff;
    padding: 12px 32px;
    font-size: 0.95rem;
    font-weight: 600;
    border: none;
    border-radius: var(--radius-full);
    cursor: pointer;
    display: block;
    margin: 24px auto;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(30, 64, 175, 0.2);
}

.explore-button:hover {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(30, 64, 175, 0.3);
}

.card-section {
    margin: 32px 0;
    padding: 20px 0;
    position: relative;
}

.card-section h2 {
    font-family: 'Plus Jakarta Sans', 'Inter', sans-serif;
    font-size: 1.4rem;
    color: var(--text-primary);
    margin-bottom: 20px;
    text-align: center;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.carousel-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.card-container {
    display: flex;
    overflow-x: auto;
    gap: 20px;
    padding: 12px 4px;
    scroll-behavior: smooth;
    scrollbar-width: thin;
    scrollbar-color: var(--primary) #f1f5f9;
    width: 100%;
}

.card-container::-webkit-scrollbar {
    height: 6px;
}

.card-container::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: var(--radius-full);
}

.card-nav-btn {
    background: #ffffff;
    color: var(--text-primary);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-full);
    width: 2.5rem;
    height: 2.5rem;
    font-size: 1.1rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 10;
    flex-shrink: 0;
    box-shadow: var(--shadow-subtle);
}

.card-nav-btn:hover {
    background: #f1f5f9;
    color: var(--primary);
    transform: scale(1.05);
}

.card {
    flex: 0 0 auto;
    width: 250px;
    background: #ffffff;
    border-radius: var(--radius-md);
    padding: 20px;
    text-align: left;
    transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 190px;
    border: 1px solid var(--border-light);
    box-shadow: var(--shadow-card);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-hover);
    border-color: #cbd5e1;
}

.card h3 {
    font-family: 'Plus Jakarta Sans', 'Inter', sans-serif;
    font-size: 1.1rem;
    margin-bottom: 10px;
    color: var(--text-primary);
    font-weight: 700;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 14px;
    line-height: 1.5;
    overflow: hidden;
}

.card a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
    font-size: 0.88rem;
    margin-top: auto;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: color 0.2s ease;
}

.card a:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

footer {
    text-align: center;
    padding: 2.5rem 1rem;
    background: #ffffff;
    color: var(--text-muted);
    border-top: 1px solid var(--border-light);
    font-size: 0.9rem;
}

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

@media (max-width: 768px) {
    header h1 { font-size: 1.5rem; }
    .container { width: 95%; padding: 20px; }
    .card { width: 210px; min-height: 175px; }
}