:root {
    --primary-color: #3a86ff;
    --secondary-color: #8338ec;
    --accent-color: #06d6a0;
    --background-color: #0f172a;
    --card-background: #1e293b;
    --text-color: #f8fafc;
    --text-secondary: #94a3b8;
    --border-color: #334155;
    --highlight-color: #ffd166;
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--background-color);
    color: var(--text-color);
    line-height: 1.6;
    overflow-x: hidden;
    background-image:
        radial-gradient(circle at 25% 25%, rgba(58, 134, 255, 0.1) 0%, transparent 50%),
        radial-gradient(circle at 75% 75%, rgba(131, 56, 236, 0.1) 0%, transparent 50%);
    background-attachment: fixed;
}

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

/* Header Styles */
.tech-header {
    background-color: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    display: flex;
    align-items: center;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-color);
}

.logo i {
    margin-right: 10px;
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 2rem;
}

.nav-links a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
}

.nav-links a i {
    margin-right: 8px;
    color: var(--accent-color);
}

.nav-links a:hover {
    color: var(--primary-color);
}

.mobile-menu {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-color);
}

/* Hero Section */
.hero {
    padding: 4rem 0;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    opacity: 0.05;
    z-index: -1;
    transform: skewY(-5deg);
    transform-origin: top left;
}

.hero .container {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
}

.book-cover {
    flex: 1;
    min-width: 250px;
    padding: 20px;
    position: relative;
}

.cover-shadow {
    position: relative;
    transform-style: preserve-3d;
    transition: transform 0.5s ease;
}

.cover-shadow:hover {
    transform: translateY(-10px) rotate(5deg);
}

.cover-shadow img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    border: 1px solid var(--border-color);
}

.cover-shadow::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    opacity: 0.2;
    border-radius: 10px;
    z-index: -1;
    transform: translateZ(-10px) translateX(10px) translateY(10px);
}

.book-info {
    flex: 2;
    min-width: 300px;
    padding: 20px;
}

.book-info h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.author {
    font-size: 1.1rem;
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.ratings {
    margin-bottom: 1.5rem;
    color: var(--highlight-color);
}

.ratings span {
    color: var(--text-secondary);
    margin-left: 10px;
}

.description {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    line-height: 1.8;
    color: var(--text-secondary);
}

.buy-btn {
    display: inline-block;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    color: white;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    box-shadow: 0 4px 15px rgba(58, 134, 255, 0.4);
    display: flex;
    align-items: center;
}

.buy-btn i {
    margin-right: 10px;
}

.buy-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(58, 134, 255, 0.6);
}

/* Section Styles */
section {
    padding: 4rem 0;
    position: relative;
}

section h2 {
    font-size: 2rem;
    margin-bottom: 2rem;
    text-align: center;
    position: relative;
    display: inline-block;
    left: 50%;
    transform: translateX(-50%);
}

section h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 100%;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    border-radius: 3px;
}

section h2 i {
    margin-right: 10px;
    color: var(--accent-color);
}

/* Overview Section */
.overview-content {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
}

.tech-card {
    background-color: var(--card-background);
    border-radius: 10px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    backdrop-filter: blur(5px);
    position: relative;
    overflow: hidden;
}

.tech-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
}

.tech-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
}

.overview-content .tech-card {
    flex: 1;
    min-width: 300px;
}

.tech-card h3 {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--primary-color);
    display: flex;
    align-items: center;
}

.tech-card h3 i {
    margin-right: 10px;
    color: var(--accent-color);
}

.overview-content ul {
    list-style: none;
}

.overview-content li {
    margin-bottom: 1rem;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-secondary);
}

.overview-content li::before {
    content: '>';
    position: absolute;
    left: 0;
    color: var(--accent-color);
    font-weight: bold;
}

.overview-content strong {
    color: var(--text-color);
}

/* Contents Section */
.contents-card {
    width: 100%;
}

.toc-tabs {
    display: flex;
    margin-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
    overflow-x: auto;
    scrollbar-width: none;
}

.toc-tabs::-webkit-scrollbar {
    display: none;
}

.toc-tab {
    padding: 10px 20px;
    background-color: transparent;
    border: none;
    color: var(--text-secondary);
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.toc-tab.active {
    color: var(--primary-color);
    border-bottom: 3px solid var(--primary-color);
}

.toc-tab:hover:not(.active) {
    color: var(--text-color);
    border-bottom: 3px solid var(--border-color);
}

.toc-content {
    position: relative;
}

.toc-panel {
    display: none;
}

.toc-panel.active {
    display: block;
    animation: fadeIn 0.5s ease;
}

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

.toc-panel h3 {
    margin-bottom: 1rem;
    color: var(--accent-color);
}

.toc-panel ul {
    list-style: none;
}

.toc-panel li {
    margin-bottom: 0.8rem;
    padding-left: 1.5rem;
    position: relative;
    color: var(--text-secondary);
    transition: all 0.3s ease;
}

.toc-panel li:hover {
    color: var(--text-color);
    transform: translateX(5px);
}

.toc-panel li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-weight: bold;
}

/* Value Section */
.value-content {
    display: flex;
    justify-content: center;
}

.value-content .tech-card {
    width: 100%;
}

.value-item {
    display: flex;
    margin-bottom: 2rem;
    padding-bottom: 2rem;
    border-bottom: 1px solid var(--border-color);
}

.value-item:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.value-icon {
    flex: 0 0 50px;
    height: 50px;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1.5rem;
    color: white;
    font-size: 1.2rem;
    box-shadow: 0 4px 15px rgba(58, 134, 255, 0.3);
}

.value-text {
    flex: 1;
}

.value-text h3 {
    margin-bottom: 0.5rem;
    color: var(--accent-color);
}

.value-text p {
    color: var(--text-secondary);
}

/* Reviews Section */
.reviews-content {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    justify-content: center;
}

.review-card {
    flex: 1;
    min-width: 300px;
    max-width: 400px;
}

.reviewer-info {
    display: flex;
    align-items: center;
    margin-bottom: 1.5rem;
}

.reviewer-avatar {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 1.5rem;
    color: white;
    font-size: 1.5rem;
    box-shadow: 0 4px 15px rgba(58, 134, 255, 0.3);
}

.reviewer-name h4 {
    margin-bottom: 0.2rem;
    color: var(--text-color);
}

.reviewer-name p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.review-content {
    margin-bottom: 1.5rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

.review-rating {
    color: var(--highlight-color);
}

/* Footer Styles */
.tech-footer {
    background-color: var(--card-background);
    border-top: 1px solid var(--border-color);
    padding: 3rem 0 1.5rem;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-info,
.footer-links,
.footer-contact {
    flex: 1;
    min-width: 200px;
}

.footer-info h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    color: var(--text-color);
}

.footer-info h3 i {
    margin-right: 10px;
    color: var(--primary-color);
}

.footer-info p {
    color: var(--text-secondary);
}

.footer-links h4,
.footer-contact h4 {
    font-size: 1.2rem;
    margin-bottom: 1rem;
    color: var(--text-color);
}

.footer-links ul,
.footer-contact ul {
    list-style: none;
}

.footer-links li,
.footer-contact li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    transition: all 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary-color);
}

.footer-contact li {
    display: flex;
    align-items: center;
    color: var(--text-secondary);
}

.footer-contact i {
    margin-right: 10px;
    color: var(--accent-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.footer-bottom a {
    color: var(--primary-color);
    text-decoration: none;
}

.footer-bottom a:hover {
    text-decoration: underline;
}

/* Responsive Styles */
@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .mobile-menu {
        display: block;
    }

    .book-info h1 {
        font-size: 2rem;
    }

    section h2 {
        font-size: 1.8rem;
    }
}

@media (max-width: 576px) {
    .book-info h1 {
        font-size: 1.8rem;
    }

    .description {
        font-size: 1rem;
    }

    .buy-btn {
        padding: 10px 20px;
        font-size: 0.9rem;
    }

    section h2 {
        font-size: 1.6rem;
    }

    .tech-card {
        padding: 1.5rem;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.8s ease forwards;
    opacity: 0;
}

.delay-1 {
    animation-delay: 0.2s;
}

.delay-2 {
    animation-delay: 0.4s;
}

.delay-3 {
    animation-delay: 0.6s;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--background-color);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--secondary-color);
}