/* PrintHub - 현대적이고 세련된 스타일시트 */

/* ===== 기본 설정 ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --secondary-gradient: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --header-gradient: linear-gradient(135deg, #1e3c72 0%, #2a5298 100%);
    --primary-color: #667eea;
    --secondary-color: #764ba2;
    --success-color: #28a745;
    --warning-color: #ffc107;
    --danger-color: #dc3545;
    --text-primary: #333;
    --text-secondary: #666;
    --text-light: #999;
    --bg-light: #f8f9fa;
    --bg-white: #ffffff;
    --border-color: #e0e0e0;
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.08);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.16);
    --shadow-xl: 0 12px 48px rgba(0, 0, 0, 0.2);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans KR', Roboto, 'Helvetica Neue', Arial, sans-serif;
    margin: 0;
    padding: 0;
    background: var(--primary-gradient);
    background-attachment: fixed;
    min-height: 100vh;
    padding-bottom: 100px;
    color: var(--text-primary);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* ===== 헤더 스타일 ===== */
header {
    background: var(--header-gradient);
    color: white;
    padding: 20px 20px;
    text-align: center;
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(10px);
    background: linear-gradient(135deg, rgba(30, 60, 114, 0.95) 0%, rgba(42, 82, 152, 0.95) 100%);
}

header h1 {
    font-size: 2.2em;
    margin-bottom: 12px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    font-weight: 700;
    letter-spacing: -0.5px;
}

nav ul {
    list-style: none;
    padding: 0;
    margin: 12px 0 0 0;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
}

nav ul li {
    display: inline-block;
}

nav ul li a {
    color: white;
    text-decoration: none;
    font-weight: 500;
    padding: 10px 18px;
    border-radius: 20px;
    transition: var(--transition);
    display: inline-block;
    font-size: 0.95em;
    position: relative;
    overflow: hidden;
}

nav ul li a::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    transition: left 0.3s ease;
}

nav ul li a:hover::before {
    left: 0;
}

nav ul li a:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* ===== 메인 컨텐츠 ===== */
main {
    width: 90%;
    max-width: 1200px;
    margin: 40px auto;
    padding: 40px;
    background: var(--bg-white);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    min-height: calc(100vh - 350px);
    animation: fadeInUp 0.6s ease;
}

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

/* ===== 퀵 견적 섹션 ===== */
#quick-quote {
    background: var(--primary-gradient);
    color: white;
    padding: 40px 30px;
    margin-bottom: 40px;
    text-align: center;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}

#quick-quote::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: rotate 20s linear infinite;
}

@keyframes rotate {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

#quick-quote h2 {
    margin-bottom: 24px;
    font-size: 1.9em;
    font-weight: 700;
    position: relative;
    z-index: 1;
}

#quick-quote form {
    display: flex;
    flex-direction: column;
    gap: 18px;
    max-width: 500px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

#quick-quote input[type="file"] {
    padding: 14px;
    border-radius: var(--radius-md);
    border: 2px dashed rgba(255, 255, 255, 0.6);
    background: rgba(255, 255, 255, 0.1);
    color: white;
    cursor: pointer;
    transition: var(--transition);
}

#quick-quote input[type="file"]:hover {
    border-color: rgba(255, 255, 255, 0.8);
    background: rgba(255, 255, 255, 0.15);
}

#quick-quote input[type="file"]::file-selector-button {
    background: white;
    color: var(--primary-color);
    border: none;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    cursor: pointer;
    font-weight: 600;
    margin-right: 12px;
    transition: var(--transition);
}

#quick-quote input[type="file"]::file-selector-button:hover {
    transform: scale(1.05);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

#quick-quote button {
    background: white;
    color: var(--primary-color);
    border: none;
    padding: 16px 32px;
    border-radius: 30px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

#quick-quote button:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}

/* ===== 푸터 ===== */
footer {
    background: var(--header-gradient);
    color: white;
    text-align: center;
    padding: 30px 20px;
    position: fixed;
    bottom: 0;
    width: 100%;
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    background: linear-gradient(135deg, rgba(30, 60, 114, 0.95) 0%, rgba(42, 82, 152, 0.95) 100%);
}

footer p {
    margin: 8px 0;
    font-size: 0.9em;
    opacity: 0.9;
}

/* ===== 이미지 갤러리 ===== */
.image-gallery {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 24px;
    margin: 24px 0;
}

.image-gallery img {
    width: 400px;
    height: 300px;
    object-fit: cover;
    border-radius: var(--radius-md);
    margin-top: 0 !important;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
}

.image-gallery img:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

/* ===== 배경음악 플레이어 ===== */
.music-player {
    position: fixed;
    bottom: 100px;
    right: 20px;
    background-color: var(--bg-white);
    border: none;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    z-index: 999;
    min-width: 260px;
    max-width: 300px;
    overflow: hidden;
    animation: slideInRight 0.5s ease;
}

@keyframes slideInRight {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.music-player-header {
    background: var(--primary-gradient);
    color: white;
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.music-player-header span {
    font-weight: 600;
    font-size: 14px;
}

.toggle-music {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--transition);
}

.toggle-music:hover {
    background-color: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.music-player-content {
    padding: 16px;
}

.music-player-content audio {
    width: 100%;
    max-width: 260px;
}

/* ===== 카드 컴포넌트 ===== */
.card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(102, 126, 234, 0.2);
}

/* ===== 버튼 스타일 ===== */
.btn {
    padding: 14px 28px;
    border: none;
    border-radius: 30px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    display: inline-block;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn-primary {
    background: var(--primary-gradient);
    color: white;
    box-shadow: 0 4px 16px rgba(102, 126, 234, 0.4);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(102, 126, 234, 0.6);
}

.btn-secondary {
    background: linear-gradient(135deg, #6c757d 0%, #5a6268 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(108, 117, 125, 0.3);
}

.btn-secondary:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 18px rgba(108, 117, 125, 0.4);
}

/* ===== 폼 스타일 ===== */
.form-group {
    margin-bottom: 24px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.95em;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    font-size: 1em;
    transition: var(--transition);
    font-family: inherit;
    background: var(--bg-white);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

/* ===== 타이포그래피 ===== */
h2, h3, h4 {
    color: var(--text-primary);
    margin-bottom: 20px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

h2 {
    font-size: 2.2em;
}

h3 {
    font-size: 1.6em;
}

h4 {
    font-size: 1.3em;
}

p {
    color: var(--text-secondary);
    line-height: 1.7;
}

/* ===== 홈 그리드 ===== */
.home-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    margin-top: 40px;
}

.notice-list {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.notice-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: var(--bg-light);
    border-radius: var(--radius-md);
    transition: var(--transition);
    border-left: 4px solid transparent;
}

.notice-item:hover {
    background: #e9ecef;
    border-left-color: var(--primary-color);
    transform: translateX(4px);
}

.notice-badge {
    padding: 6px 14px;
    background: var(--primary-gradient);
    color: white;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: 600;
    white-space: nowrap;
    box-shadow: var(--shadow-sm);
}

/* ===== 반응형 디자인 ===== */
@media (max-width: 768px) {
    main {
        width: 95%;
        padding: 24px;
        margin: 20px auto;
    }
    
    header h1 {
        font-size: 1.6em;
    }
    
    nav ul {
        flex-direction: row;
        gap: 6px;
    }
    
    nav ul li a {
        padding: 8px 14px;
        font-size: 0.85em;
    }

    .home-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .image-gallery img {
        width: 100%;
        max-width: 100%;
        height: auto;
        min-height: 200px;
    }

    .music-player {
        bottom: 90px;
        right: 10px;
        min-width: 240px;
        max-width: calc(100vw - 20px);
    }

    #quick-quote {
        padding: 30px 20px;
    }

    #quick-quote h2 {
        font-size: 1.5em;
    }

    .card {
        padding: 20px;
    }
}

@media (max-width: 480px) {
    header h1 {
        font-size: 1.4em;
    }

    nav ul {
        flex-direction: column;
        gap: 4px;
    }

    nav ul li a {
        width: 100%;
        text-align: center;
    }

    main {
        padding: 16px;
    }

    h2 {
        font-size: 1.6em;
    }

    h3 {
        font-size: 1.3em;
    }
}

/* ===== 스크롤바 스타일 ===== */
::-webkit-scrollbar {
    width: 10px;
}

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

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

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

/* ===== 로딩 애니메이션 ===== */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

/* ===== 유틸리티 클래스 ===== */
.text-center {
    text-align: center;
}

.text-primary {
    color: var(--primary-color);
}

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

.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mb-1 { margin-bottom: 8px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }

/* ===== 추가 애니메이션 ===== */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease;
}

.slide-in-left {
    animation: slideInLeft 0.6s ease;
}

.slide-in-right {
    animation: slideInRight 0.6s ease;
}

.scale-in {
    animation: scaleIn 0.4s ease;
}

/* ===== 호버 효과 강화 ===== */
.card,
.btn,
.catalog-card {
    position: relative;
    overflow: hidden;
}

.card::after,
.btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.card:hover::after,
.btn:hover::after {
    width: 300px;
    height: 300px;
}

/* ===== 포커스 스타일 개선 ===== */
input:focus,
select:focus,
textarea:focus,
button:focus {
    outline: none;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

/* ===== 선택 텍스트 스타일 ===== */
::selection {
    background: rgba(102, 126, 234, 0.3);
    color: #333;
}

::-moz-selection {
    background: rgba(102, 126, 234, 0.3);
    color: #333;
}
