/* css/style.css */
:root {
    --primary: #0f172a;    /* Deep Navy */
    --accent: #3b82f6;     /* Bright Blue for buttons */
    --bg-light: #f8fafc;   /* Very light gray background */
    --text-dark: #1e293b;
    --text-light: #94a3b8;
    --white: #ffffff;
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Typography */
h1, h2, h3 { line-height: 1.2; }
a { text-decoration: none; color: inherit; }

/* Navigation */
header {
    background-color: var(--primary);
    color: var(--white);
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

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

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    border: 2px solid var(--white);
    padding: 5px 10px;
}

.nav-links a {
    color: var(--text-light);
    margin-left: 20px;
    font-weight: 500;
    transition: color 0.3s;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--white);
}

/* Hero Section */
.hero {
    background: linear-gradient(rgba(15, 23, 42, 0.9), rgba(15, 23, 42, 0.8)), url('https://source.unsplash.com/random/1600x900/?library,science') no-repeat center center/cover;
    color: var(--white);
    text-align: center;
    padding: 5rem 1rem;
    margin-bottom: 2rem;
}

.hero h1 { font-size: 3rem; margin-bottom: 1rem; }
.hero p { font-size: 1.2rem; margin-bottom: 2rem; color: #cbd5e1; }
.btn {
    background-color: var(--accent);
    color: var(--white);
    padding: 10px 25px;
    border-radius: 5px;
    font-weight: 600;
    transition: background 0.3s;
}
.btn:hover { background-color: #2563eb; }

/* Library Grid */
.library-section { padding: 2rem 0; flex: 1; }
.section-title { margin-bottom: 2rem; text-align: center; color: var(--primary); }

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.card {
    background: var(--white);
    border-radius: 8px;
    box-shadow: var(--shadow);
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border-top: 4px solid var(--accent);
    transition: transform 0.2s;
}

.card:hover { transform: translateY(-5px); }

.card-icon {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 1rem;
    opacity: 0.8;
}

.card h3 { font-size: 1.1rem; margin-bottom: 0.5rem; color: var(--text-dark); }
.card p { font-size: 0.9rem; color: var(--text-light); margin-bottom: 1.5rem; }

.card-actions {
    display: flex;
    gap: 10px;
    margin-top: auto;
}

.btn-small {
    flex: 1;
    padding: 8px;
    text-align: center;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 600;
}

.btn-read { background: #e2e8f0; color: var(--text-dark); }
.btn-read:hover { background: #cbd5e1; }
.btn-dl { background: var(--primary); color: var(--white); }
.btn-dl:hover { background: #1e293b; }

/* Footer */
footer {
    background: var(--primary);
    color: var(--text-light);
    text-align: center;
    padding: 1.5rem;
    margin-top: auto;
}

.logo-link {
    display: flex;
    align-items: center;
}
.logo-link img {
    max-height: 60px; /* Limits height */
    width: auto;      /* Maintains aspect ratio */
    display: block;   /* Prevents weird spacing */
}

.logo-img {
    height: 50px; /* Adjust this based on your logo's shape */
    width: auto;  /* Keeps the aspect ratio correct */
    object-fit: contain;
}

/* TikTok Button Styling */
.tiktok-btn {
    background-color: #000000; /* TikTok Black */
    color: #ffffff !important; /* Force white text */
    padding: 8px 15px;
    border-radius: 20px;
    margin-left: 20px;
    font-size: 1.1rem;
    transition: transform 0.2s, box-shadow 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.tiktok-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 255, 255, 0.3); /* Cyan glow effect */
    background-color: #1a1a1a;
}