:root {
    --bg: #ffffff;
    --bg-elevated: #f7f7f8;
    --accent: #10a37f;
    --accent-hover: #0e8f6f;
    --text-main: #0d0d0d;
    --text-sub: #6e6e80;
    --border: #e5e5e5;
    --error: #d1293d;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--bg);
    color: var(--text-main);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Apple SD Gothic Neo",
        "Pretendard", "Malgun Gothic", sans-serif;
    min-height: 100vh;
}

.page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* ----- 가운데 정렬 화면 (랜딩 / 코드 입력 / 업로드) ----- */
.center-screen {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 40px 20px;
    gap: 18px;
}

.brand-title {
    font-size: clamp(48px, 10vw, 96px);
    font-weight: 700;
    letter-spacing: -2px;
    margin: 0;
    color: var(--text-main);
}

.brand-subtitle {
    color: var(--text-sub);
    font-size: 17px;
    margin: 0 0 16px 0;
}

.brand-subtitle.small {
    font-size: 14px;
    max-width: 420px;
}

.section-title {
    font-size: 26px;
    font-weight: 600;
    margin: 0 0 6px 0;
    color: var(--text-main);
}

/* ----- 버튼 ----- */
.btn {
    display: inline-block;
    border: 1px solid transparent;
    border-radius: 8px;
    padding: 12px 28px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.15s ease, border-color 0.15s ease, opacity 0.1s ease;
}

.btn-primary {
    background: var(--text-main);
    color: #ffffff;
}

.btn-primary:hover {
    background: #2a2a2a;
}

.btn-primary:disabled {
    background: #b6b6c2;
    cursor: not-allowed;
}

.btn-secondary {
    background: #ffffff;
    color: var(--text-main);
    border: 1px solid var(--border);
    margin-bottom: 24px;
}

.btn-secondary:hover {
    background: var(--bg-elevated);
}

.btn-large {
    padding: 15px 44px;
    font-size: 17px;
    border-radius: 10px;
}

/* ----- 코드 입력 화면 ----- */
.code-form {
    display: flex;
    gap: 10px;
    align-items: center;
}

.code-form input[type="text"] {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 10px;
    padding: 12px 16px;
    font-size: 20px;
    letter-spacing: 4px;
    color: var(--text-main);
    text-align: center;
    width: 220px;
}

.code-form input[type="text"]:focus {
    outline: none;
    border-color: var(--text-main);
    box-shadow: 0 0 0 3px rgba(13, 13, 13, 0.06);
}

.error-text {
    color: var(--error);
    font-size: 14px;
    margin: 0;
}

/* ----- 업로드 화면 ----- */
.upload-form {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    width: 100%;
    max-width: 420px;
}

.file-drop {
    width: 100%;
    border: 1.5px dashed var(--border);
    border-radius: 14px;
    padding: 40px 20px;
    color: var(--text-sub);
    background: var(--bg-elevated);
    cursor: pointer;
    transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
}

.file-drop:hover {
    border-color: var(--text-main);
    color: var(--text-main);
    background: #f0f0f1;
}

.file-drop input[type="file"] {
    display: none;
}

.loading-text {
    display: none;
    color: var(--text-sub);
    font-size: 14px;
    margin-top: 10px;
}

/* ----- 결과 화면 ----- */
.results-wrap {
    flex: 1;
    max-width: 900px;
    margin: 0 auto;
    padding: 50px 20px 100px;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    width: 100%;
}

.results-list {
    display: flex;
    flex-direction: column;
    gap: 32px;
    width: 100%;
    margin-top: 20px;
}

.result-card {
    background: #ffffff;
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    width: 100%;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.result-label {
    margin: 0 0 14px 0;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-main);
}

.result-media {
    width: 100%;
    border-radius: 10px;
    display: block;
    background: #f0f0f1;
    border: 1px solid var(--border);
}
