/* Reset & nền tối */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background: #0d1117;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.container {
    background: #161b22;
    border-radius: 20px;
    padding: 35px 30px 30px;
    max-width: 650px;
    width: 100%;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.7);
    border: 1px solid #30363d;
}

h1 {
    text-align: center;
    color: #f0f6fc;
    font-weight: 300;
    font-size: 28px;
    letter-spacing: 1px;
    margin-bottom: 25px;
}

/* Tabs */
.tabs {
    display: flex;
    gap: 4px;
    background: #0d1117;
    border-radius: 12px;
    padding: 4px;
    margin-bottom: 25px;
    border: 1px solid #21262d;
}

.tab {
    flex: 1;
    padding: 10px 0;
    border: none;
    background: transparent;
    color: #8b949e;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    border-radius: 10px;
    transition: background 0.25s, color 0.25s;
}

.tab:hover {
    background: #21262d;
    color: #c9d1d9;
}

.tab.active {
    background: #30363d;
    color: #f0f6fc;
}

/* Tab content */
.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(6px); }
    to   { opacity: 1; transform: translateY(0); }
}

.converter-box {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

label {
    color: #c9d1d9;
    font-size: 15px;
    font-weight: 500;
}

input {
    background: #0d1117;
    border: 1px solid #30363d;
    border-radius: 12px;
    padding: 14px 18px;
    font-size: 18px;
    color: #f0f6fc;
    outline: none;
    transition: border-color 0.3s;
    width: 100%;
}

input:focus {
    border-color: #58a6ff;
}

input::placeholder {
    color: #484f58;
    font-size: 15px;
}

button {
    padding: 12px 0;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.25s, transform 0.1s;
}

button:active {
    transform: scale(0.97);
}

.btn-primary {
    background: #238636;
    color: #fff;
}
.btn-primary:hover {
    background: #2ea043;
}

.btn-secondary {
    background: #1f6feb;
    color: #fff;
}
.btn-secondary:hover {
    background: #388bfd;
}

/* Kết quả */
.result-area {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #21262d;
}

.result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.result-header label {
    font-size: 15px;
}

.copy-btn {
    background: #21262d;
    color: #c9d1d9;
    border: 1px solid #30363d;
    padding: 6px 14px;
    font-size: 13px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s;
}

.copy-btn:hover {
    background: #30363d;
    border-color: #58a6ff;
    color: #f0f6fc;
}

.copy-btn.copied {
    background: #238636;
    border-color: #238636;
    color: #fff;
}

.output-box {
    background: #0d1117;
    border: 1px solid #30363d;
    border-radius: 12px;
    padding: 16px 18px;
    min-height: 70px;
    font-size: 18px;
    color: #f0f6fc;
    word-break: break-word;
    overflow-wrap: break-word;
    line-height: 1.6;
    display: flex;
    align-items: center;
    transition: border-color 0.3s;
    max-height: none;
    height: auto;
    white-space: pre-wrap;
}

.output-box:not(:empty) {
    border-color: #58a6ff;
}

.note {
    margin-top: 20px;
    padding-top: 14px;
    border-top: 1px solid #21262d;
    text-align: center;
}

.note p {
    color: #8b949e;
    font-size: 14px;
}