/* PDF-DS Integration Styles */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-sans, 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, 'Noto Sans KR', sans-serif);
    background-color: var(--color-bg-primary, #ffffff);
    color: var(--color-text-primary, #09090b);
    line-height: 1.5;
    transition: background-color 0.4s ease, color 0.4s ease;
}

.material-symbols-rounded {
    vertical-align: middle;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--space-300, 24px);
}

/* Hero Section Adjustments */
.hero-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-600, 48px);
}

.hero-text {
    flex: 1;
}

.hero-visual {
    flex: 1;
    display: flex;
    justify-content: center;
    perspective: 1000px;
}

/* Avatar 3D Elements */
#avatarCard {
    position: relative;
    overflow: hidden;
    cursor: pointer;
    transform-style: preserve-3d;
}

#avatarCard.resting {
    transition: transform 0.6s cubic-bezier(0.05, 0.7, 0.1, 1), box-shadow 0.6s ease-out;
}

.glow-effect {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    mix-blend-mode: color-dodge;
    background-image: 
        linear-gradient(105deg, transparent 20%, rgba(255, 255, 255, 0.6) 25%, rgba(255, 255, 255, 0.6) 30%, transparent 35%),
        url('/holo_texture.png');
    background-size: 200% 200%, 150% 150%;
    background-repeat: no-repeat, no-repeat;
    opacity: 0.8;
    z-index: 2;
}

/* Project Grid layout */
.project-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--space-300, 24px);
}

.card-image {
    height: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 1px solid var(--color-border-default);
    margin: -16px -16px 16px -16px; /* Offset pdf-panel padding */
    border-radius: var(--radius-lg, 16px) var(--radius-lg, 16px) 0 0;
}

.card-content {
    flex: 1;
}

/* Search Panel (Pull down interaction) */
.search-panel {
    width: 100%;
    height: 0px;
    background-color: var(--color-bg-secondary);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    overflow: hidden;
    position: relative;
    border-bottom: 1px solid transparent;
    will-change: height;
}

.search-panel.transitioning {
    transition: height 0.4s cubic-bezier(0.2, 0, 0, 1);
}

.search-panel.open {
    height: 80px;
    border-bottom-color: var(--color-border-default);
}

.search-container {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 80px;
    display: flex;
    align-items: center;
    gap: var(--space-200, 16px);
    padding: 0 var(--space-300, 24px);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.search-panel.open .search-container,
.search-panel.dragging .search-container {
    opacity: 1;
}

#searchInput {
    flex: 1;
    height: 48px;
    border: none;
    background: transparent;
    font-size: 1.25rem;
    color: var(--color-text-primary);
    outline: none;
    font-family: inherit;
}

#searchInput::placeholder {
    color: var(--color-text-secondary);
}

/* Bottom Sheet */
.search-results-sheet {
    transform: translateY(100%);
    transition: transform 0.6s cubic-bezier(0.05, 0.7, 0.1, 1);
}

.search-results-sheet.active {
    transform: translateY(0);
}

.no-results {
    display: none;
    text-align: center;
    padding: var(--space-400, 32px);
    color: var(--color-text-secondary);
}

/* List Items */
.search-list-item {
    background-color: var(--color-bg-primary);
    border: 1px solid var(--color-border-default);
    border-radius: var(--radius-md, 8px);
    margin-bottom: var(--space-100, 8px);
    overflow: hidden;
    transition: background-color 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
}

.search-list-item:hover {
    background-color: var(--color-bg-secondary);
    transform: translateY(-2px);
    box-shadow: var(--shadow-hardware-bevel);
}

.list-item-header {
    display: flex;
    align-items: center;
    padding: var(--space-200, 16px);
    cursor: pointer;
}

.list-item-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-sm, 4px);
    background-color: var(--color-bg-secondary);
    border: 1px solid var(--color-border-default);
    color: var(--color-text-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: var(--space-200, 16px);
}

.list-item-title {
    flex: 1;
    font-weight: 600;
    color: var(--color-text-primary);
    font-size: 1rem;
}

.expand-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: var(--color-text-secondary);
    transition: transform 0.4s ease, background-color 0.2s;
}

.search-list-item:hover .expand-btn {
    background-color: var(--color-border-default);
}

.search-list-item.expanded .expand-btn {
    transform: rotate(90deg);
}

.list-item-body {
    padding: 0 var(--space-200, 16px);
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transition: max-height 0.5s ease, opacity 0.4s ease, padding 0.5s ease;
}

.search-list-item.expanded .list-item-body {
    max-height: 300px;
    opacity: 1;
    padding: 0 var(--space-200, 16px) var(--space-300, 24px) 72px; /* Indent to match title */
}

/* Language Dropdown Menu */
.lang-dropdown-container {
    position: relative;
    display: inline-block;
}

.lang-dropdown-menu {
    position: absolute;
    top: 44px;
    right: 0;
    z-index: 200;
    min-width: 120px;
    transform: scale(0.9);
    opacity: 0;
    transform-origin: top right;
    transition: transform 0.15s ease, opacity 0.15s ease;
    pointer-events: none;
    visibility: hidden;
}

.lang-dropdown-menu.open {
    transform: scale(1);
    opacity: 1;
    pointer-events: auto;
    visibility: visible;
}

/* Responsive */
.mobile-menu {
    display: none;
}

@media (max-width: 1199px) {
    .mobile-menu {
        display: flex;
    }
    .nav-links {
        display: none;
    }
}
