/* Common CSS for InfiniTree Website - All Pages */

/* ========================================
   Header - Remove default padding
   ======================================== */
.navbar {
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    padding-left: 30px !important;
    min-height: auto !important;
}

.navbar-start {
    flex: none !important;
    width: auto !important;
}

/* Header menu font */
.navbar-center span,
.navbar-end a {
    font-family: "Inter", "Malgun Gothic", "맑은 고딕", sans-serif;
}

/* ========================================
   Logo
   ======================================== */
.infinitree-logo {
    width: 40px;
    height: 40px;
    position: relative;
    border: 3px solid #10B981;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #10B981, #059669);
}

.infinitree-logo::before {
    content: '';
    position: absolute;
    width: 12px;
    height: 8px;
    background: #065F46;
    bottom: 8px;
    clip-path: polygon(0% 100%, 50% 0%, 100% 100%);
}

.infinitree-logo::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 4px;
    background: transparent;
    border: 2px solid #065F46;
    border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
    transform: rotate(45deg);
}

/* ========================================
   Smooth Scrolling
   ======================================== */
html {
    scroll-behavior: smooth;
}

/* ========================================
   Custom Button Styles
   ======================================== */
.btn-primary {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn-primary:hover::before {
    left: 100%;
}

/* ========================================
   Tab System (공통 컴포넌트)
   ======================================== */
.tab-content {
    display: none;
    animation: fadeIn 0.5s ease-in-out;
}

.tab-content.active {
    display: block;
}

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

.tab {
    transition: all 0.3s ease;
}

.tab:hover {
    background-color: #F3F4F6;
}

.tab.tab-active {
    background-color: #10B981;
    color: white;
}

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

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #10B981;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #059669;
}

/* ========================================
   Dropdown Menu Enhancements
   ======================================== */
.dropdown-content {
    animation: dropdownSlideDown 0.15s ease-out;
    transform-origin: top center;
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
}

@keyframes dropdownSlideDown {
    from {
        opacity: 0;
        transform: translateY(-5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Show dropdown on hover - both on trigger and content */
.dropdown:hover > .dropdown-content,
.dropdown-content:hover {
    display: flex !important;
}

/* Keep button styled when hovering */
.dropdown:hover > div[role="button"] {
    color: #10B981;
    background-color: #F9FAFB;
}

/* Menu buttons full height */
.navbar-center .menu-horizontal {
    display: flex;
    align-items: stretch;
    height: 100%;
}

.navbar-center .menu-horizontal > li {
    margin: 0;
    height: 100%;
    display: flex;
    align-items: stretch;
}

/* Position dropdown relative to full-height button */
.navbar-center .dropdown > div[role="button"] {
    position: relative;
}

.dropdown-content li a {
    font-size: 0.95rem;
    padding: 0.5rem 1rem;
}

.dropdown-content .menu-title {
    padding: 0.5rem 1rem;
}

/* Hover effect for dropdown items */
.dropdown-content li a:hover {
    transition: all 0.2s ease;
}

/* ========================================
   Focus States for Accessibility
   ======================================== */
.btn:focus,
.tab:focus,
a:focus {
    outline: 2px solid #10B981;
    outline-offset: 2px;
}

/* ========================================
   Print Styles
   ======================================== */
@media print {
    .navbar,
    .floating-element,
    .btn {
        display: none;
    }

    body {
        background: white;
        color: black;
    }

    .hero {
        background: white;
        color: black;
    }
}
