/*
Theme Name: DucPham
Author: Duc Pham
Description: A professional custom theme structure.
Version: 1.0.0
Text Domain: ducpham
*/

/* Reset & Basics */
:root {
    --primary-color: #0f172a;
    --secondary-color: #334155;
    --accent-color: #3b82f6;
    --text-color: #1e293b;
    --bg-color: #ffffff;
    --font-main: 'Inter', system-ui, -apple-system, sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

ul, ol {
    padding-left: 15px;
    margin-bottom: 1rem;
}

body {
    font-family: var(--font-main);
    color: var(--text-color);
    background-color: var(--bg-color);
    line-height: 1.6;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

a {
    color: var(--accent-color);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: var(--primary-color);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Header - Klook Style */
.klook-header {
    background: #fff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.klook-header-container {
    width: 100%;
    position: relative;
}

.klook-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
}

/* Top Navigation Row */
.klook-header-top {
    height: 72px;
    border-bottom: 1px solid #f0f0f0;
}

.klook-header-top .klook-container {
    justify-content: space-between;
    gap: 24px;
    height: 100%;
}

/* Logo */
.klook-logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.klook-logo-text {
    font-size: 24px;
    font-weight: 700;
    color: #FF5B00;
    letter-spacing: -0.5px;
}

/* Search Bar */
.klook-search {
    flex: 1;
    max-width: 500px;
}

.klook-search-form {
    position: relative;
    width: 100%;
}

.klook-search-input {
    width: 100%;
    height: 40px;
    padding: 0 48px 0 16px;
    background: #f5f5f5;
    border: none;
    border-radius: 20px;
    font-size: 14px;
    font-family: var(--font-main);
    outline: none;
    transition: background 0.2s ease;
}

.klook-search-input:focus {
    background: #ebebeb;
}

.klook-search-input::placeholder {
    color: #999;
}

.klook-search-button {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    color: #666;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease;
}

.klook-search-button:hover {
    color: #FF5B00;
}

/* Utilities */
.klook-utilities {
    display: flex;
    align-items: center;
    gap: 16px;
}

.klook-selectors {
    display: flex;
    gap: 12px;
}

.klook-selector {
    display: flex;
    align-items: center;
    gap: 4px;
    padding: 6px 8px;
    text-decoration: none;
    color: #333;
    font-size: 14px;
    font-weight: 500;
    border-radius: 4px;
    transition: background 0.2s ease;
}

.klook-selector:hover {
    background: #f5f5f5;
}

.klook-flag {
    font-size: 16px;
}

.klook-selector-text {
    font-size: 14px;
}

.klook-links {
    display: flex;
    gap: 16px;
}

.klook-link {
    color: #333;
    text-decoration: none;
    font-size: 14px;
    font-weight: 400;
    transition: color 0.2s ease;
    white-space: nowrap;
}

.klook-link:hover {
    color: #FF5B00;
}

.klook-signin-btn {
    background: #FF5B00;
    color: #fff;
    padding: 8px 24px;
    border-radius: 20px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.klook-signin-btn:hover {
    background: #e64f00;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(255, 91, 0, 0.3);
}

/* Bottom Navigation Row */
.klook-header-bottom {
    height: 48px;
}

.klook-header-bottom .klook-container {
    justify-content: space-between;
    height: 100%;
}

.klook-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
}

.klook-nav-menu {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 24px;
}

.klook-nav-menu li {
    position: relative;
}

.klook-nav-menu li:not(:last-child)::after {
    content: '';
    position: absolute;
    right: -12px;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 14px;
    background: #e0e0e0;
}

.klook-nav-menu a {
    color: #333;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s ease;
}

.klook-nav-menu a:hover {
    color: #FF5B00;
}

.klook-gift {
    display: flex;
    align-items: center;
    gap: 6px;
}

.klook-gift-link {
    color: #FF5B00;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: opacity 0.2s ease;
}

.klook-gift-link:hover {
    opacity: 0.8;
}

/* Mobile Menu Toggle */
.klook-mobile-toggle {
    display: none;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    margin-left: auto;
    border-radius: 4px;
    transition: background 0.2s ease;
    position: relative;
    z-index: 1001;
}

.klook-mobile-toggle:hover {
    background: #f5f5f5;
}

.hamburger-line {
    width: 24px;
    height: 2px;
    background: #333;
    border-radius: 2px;
    transition: all 0.3s ease;
    margin: 3px 0;
}

.klook-mobile-toggle.active .hamburger-line:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.klook-mobile-toggle.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

.klook-mobile-toggle.active .hamburger-line:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Mobile Sidebar */
.klook-mobile-sidebar {
    position: fixed;
    top: 0;
    right: -100%;
    width: 320px;
    max-width: 85vw;
    height: 100vh;
    background: #fff;
    box-shadow: -2px 0 8px rgba(0, 0, 0, 0.1);
    z-index: 1002;
    transition: right 0.3s ease;
    overflow-y: auto;
}

.klook-mobile-sidebar.active {
    right: 0;
}

.klook-mobile-sidebar-content {
    padding: 80px 24px 24px;
}

/* Mobile Overlay */
.klook-mobile-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.klook-mobile-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* Mobile User Actions */
.klook-mobile-user {
    display: flex;
    gap: 12px;
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid #f0f0f0;
}

.klook-mobile-signin,
.klook-mobile-register {
    flex: 1;
    text-align: center;
    padding: 12px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.klook-mobile-signin {
    background: #FF5B00;
    color: #fff;
}

.klook-mobile-signin:hover {
    background: #e64f00;
}

.klook-mobile-register {
    background: #f5f5f5;
    color: #333;
}

.klook-mobile-register:hover {
    background: #ebebeb;
}

/* Mobile Navigation Menu */
.klook-mobile-nav-menu {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid #f0f0f0;
}

.klook-mobile-menu-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
}

.klook-mobile-menu-list li {
    margin: 0;
    width: 100%;
}

.klook-mobile-menu-list a {
    display: block;
    padding: 14px 0;
    color: #333;
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    transition: color 0.2s ease;
}

.klook-mobile-menu-list a:hover {
    color: #FF5B00;
}

/* Mobile Links */
.klook-mobile-links {
    margin-bottom: 24px;
    padding-bottom: 24px;
    border-bottom: 1px solid #f0f0f0;
}

.klook-mobile-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 0;
    color: #333;
    font-size: 14px;
    text-decoration: none;
    transition: color 0.2s ease;
}

.klook-mobile-link:hover {
    color: #FF5B00;
}

.klook-mobile-link svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

/* Mobile Selectors */
.klook-mobile-selectors {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.klook-mobile-selector {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px;
    background: #f5f5f5;
    border-radius: 8px;
    color: #333;
    font-size: 14px;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.2s ease;
}

.klook-mobile-selector:hover {
    background: #ebebeb;
}

/* Mobile Search Dropdown */
.klook-mobile-search-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #fff;
    border-bottom: 1px solid #f0f0f0;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 0.3s ease, opacity 0.3s ease;
    z-index: 999;
}

.klook-mobile-search-dropdown.active {
    max-height: 80px;
    opacity: 1;
}

.klook-mobile-search-form {
    position: relative;
    padding: 16px;
    width: 100%;
}

.klook-mobile-search-input {
    width: 100%;
    height: 48px;
    padding: 0 56px 0 16px;
    background: #f5f5f5;
    border: none;
    border-radius: 24px;
    font-size: 16px;
    font-family: var(--font-main);
    outline: none;
    transition: background 0.2s ease;
}

.klook-mobile-search-input:focus {
    background: #ebebeb;
}

.klook-mobile-search-close {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background: none;
    border: none;
    cursor: pointer;
    color: #666;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
}

.klook-mobile-search-close:hover {
    background: #e0e0e0;
    color: #333;
}

/* Responsive */
@media (max-width: 1024px) {
    .klook-links {
        display: none;
    }

    .klook-mobile-toggle {
        display: flex;
    }
}

@media (max-width: 768px) {
    .klook-header-top {
        height: auto;
        padding: 12px 0;
    }

    .klook-header-top .klook-container {
        gap: 12px;
    }

    /* Hide search input, show only button */
    .klook-search {
        max-width: 40px;
    }

    .klook-search-input {
        display: none;
    }

    .klook-search-button {
        position: static;
        transform: none;
        width: 40px;
        height: 40px;
        background: #f5f5f5;
        border-radius: 50%;
    }

    .klook-search-button:hover {
        background: #ebebeb;
    }

    /* Hide desktop utilities */
    .klook-utilities {
        display: none;
    }

    /* Hide desktop bottom navigation */
    .klook-header-bottom {
        display: none;
    }
}

/* Footer */
.site-footer {
    background: var(--primary-color);
    color: #fff;
    padding: 3rem 0;
}

.site-footer p {
    opacity: 0.8;
}

/* =========================================================================
   WooCommerce Checkout & Order Pay Custom Styling
   ========================================================================= */

/* General Container for Checkout/Pay */
.woocommerce-checkout .woocommerce,
.woocommerce-order-pay .woocommerce {
    max-width: 900px;
    margin: 40px auto;
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
}

/* Page Title Tracker */
body.woocommerce-checkout h1.entry-title,
body.woocommerce-order-pay h1.entry-title {
    font-size: 2rem !important;
    font-weight: 800 !important;
    color: #333 !important;
    margin-bottom: 30px !important;
    border-bottom: 2px solid #FF5B00 !important;
    padding-bottom: 10px !important;
    display: inline-block !important;
}

/* Info & Error Messages */
.woocommerce-error,
.woocommerce-info,
.woocommerce-message {
    border-top-color: #FF5B00 !important;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.03);
    background-color: #fffaf5 !important;
    color: #555 !important;
    padding: 15px 20px !important;
}

.woocommerce-error::before,
.woocommerce-info::before,
.woocommerce-message::before {
    color: #FF5B00 !important;
}

/* Order Details Table */
.woocommerce table.shop_table {
    border: 1px solid #eee;
    border-radius: 8px;
    border-collapse: separate;
    margin-bottom: 30px;
    width: 100%;
}

.woocommerce table.shop_table th {
    background-color: #f9f9f9;
    font-weight: 600;
    color: #333;
    padding: 15px;
    border-bottom: 1px solid #eee;
}

.woocommerce table.shop_table td {
    padding: 15px;
    border-bottom: 1px solid #eee;
    color: #555;
    background-color: #fff;
}

.woocommerce table.shop_table tbody tr:last-child td {
    border-bottom: none;
}

.woocommerce table.shop_table tfoot th,
.woocommerce table.shop_table tfoot td {
    border-top: 1px solid #eee;
    background-color: #fdfdfd;
}

.woocommerce table.shop_table tfoot tr:last-child th,
.woocommerce table.shop_table tfoot tr:last-child td {
    font-size: 1.1rem;
    font-weight: 700;
    color: #FF5B00;
}

/* Payment Box Section */
#add_payment_method #payment,
.woocommerce-cart #payment,
.woocommerce-checkout #payment {
    background: #fdfdfd !important;
    border-radius: 12px !important;
    border: 1px solid #eee !important;
    padding: 20px !important;
}

#add_payment_method #payment ul.payment_methods,
.woocommerce-cart #payment ul.payment_methods,
.woocommerce-checkout #payment ul.payment_methods {
    border-bottom: 1px solid #eee !important;
    padding: 0 0 20px 0 !important;
}

#add_payment_method #payment div.payment_box,
.woocommerce-cart #payment div.payment_box,
.woocommerce-checkout #payment div.payment_box {
    background-color: rgba(255, 91, 0, 0.05) !important;
    color: #444 !important;
    border-radius: 8px !important;
    box-shadow: none !important;
    padding: 15px !important;
}

#add_payment_method #payment div.payment_box::before,
.woocommerce-cart #payment div.payment_box::before,
.woocommerce-checkout #payment div.payment_box::before {
    border-bottom-color: rgba(255, 91, 0, 0.05) !important;
}

/* Payment Submit Button */
#add_payment_method #payment div.form-row,
.woocommerce-cart #payment div.form-row,
.woocommerce-checkout #payment div.form-row {
    padding-top: 20px !important;
}

.woocommerce #payment #place_order,
.woocommerce-page #payment #place_order {
    background-color: #FF5B00 !important;
    color: #fff !important;
    font-weight: 700 !important;
    font-size: 1.2rem !important;
    padding: 18px 30px !important;
    border-radius: 8px !important;
    width: 100% !important;
    transition: all 0.3s ease !important;
    border: none !important;
}

.woocommerce #payment #place_order:hover,
.woocommerce-page #payment #place_order:hover {
    background-color: #e04f00 !important;
    box-shadow: 0 5px 15px rgba(255, 91, 0, 0.3) !important;
}