/* style.css */
:root {
    --primary-color: #4361ee;
    --secondary-color: #3f37c9;
    --success-color: #4cc9f0;
    --warning-color: #f72585;
    --dark-color: #2b2d42;
    --light-color: #f8f9fa;
    --gray-color: #6c757d;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 10px 15px rgba(0, 0, 0, 0.1);
    --border-radius: 10px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f5f7ff;
    color: var(--dark-color);
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 800px;
    margin: 50px auto;
    padding: 30px;
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    animation: fadeIn 0.5s ease-in-out;
}

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

h1 {
    color: var(--primary-color);
    margin-bottom: 25px;
    text-align: center;
    font-weight: 700;
    font-size: 2.2rem;
    position: relative;
    padding-bottom: 15px;
}

h1:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    border-radius: 2px;
}

.status {
    padding: 15px;
    border-radius: var(--border-radius);
    margin-bottom: 25px;
    text-align: center;
    font-weight: 600;
    transition: var(--transition);
}

.status.valid {
    background-color: rgba(76, 201, 240, 0.15);
    color: #0b5394;
    border-left: 5px solid var(--success-color);
}

.status.warning {
    background-color: rgba(247, 37, 133, 0.15);
    color: #a51c58;
    border-left: 5px solid var(--warning-color);
}

.status.expired {
    background-color: rgba(231, 76, 60, 0.15);
    color: #c0392b;
    border-left: 5px solid #e74c3c;
}

#info-area {
    background-color: var(--light-color);
    padding: 20px;
    border-radius: var(--border-radius);
    margin-bottom: 20px;
}

#info-area p {
    margin-bottom: 15px;
    font-size: 1.1rem;
}

#id-unik {
    background-color: #e9ecef;
    padding: 5px 10px;
    border-radius: 5px;
    font-weight: bold;
    letter-spacing: 1px;
}

button {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    margin-right: 10px;
    margin-bottom: 10px;
    transition: var(--transition);
    box-shadow: var(--shadow);
}

button:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

button:active {
    transform: translateY(1px);
}

#modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    animation: fadeIn 0.3s ease-in-out;
}

#modal-container {
    width: 75vw;
    height: 75vh;
    background-color: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    animation: slideUp 0.3s ease-out;
}

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

#iframe-keyboard {
    width: 100%;
    height: 100%;
    border: none;
}

/* Gaya khusus untuk app_k.html */
.keyboard-container {
    padding: 20px;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.keyboard-container h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
    text-align: center;
    font-weight: 600;
}

#voucher-input {
    width: 100%;
    padding: 15px;
    font-size: 1.5rem;
    text-align: center;
    font-family: 'Courier New', monospace;
    text-transform: uppercase;
    box-sizing: border-box;
    margin-bottom: 20px;
    letter-spacing: 2px;
    border: 2px solid #e9ecef;
    border-radius: var(--border-radius);
    transition: var(--transition);
}

#voucher-input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.2);
}

.keyboard-row {
    margin-bottom: 10px;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
}

.keyboard-key {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 45px;
    height: 45px;
    margin: 4px;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 8px;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    cursor: pointer;
    transition: var(--transition);
}

.keyboard-key:hover {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-2px);
}

.keyboard-key:active {
    transform: translateY(0);
    background-color: var(--secondary-color);
}

.key-wide {
    width: 120px;
}

.controls {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    gap: 10px;
}

.controls button {
    padding: 10px 20px;
    border-radius: var(--border-radius);
    font-weight: 600;
}

#btn-submit {
    background: linear-gradient(135deg, #4cc9f0, #4361ee);
}

#btn-close {
    background: linear-gradient(135deg, #6c757d, #495057);
}

/* Responsif */
@media (max-width: 768px) {
    .container {
        margin: 20px auto;
        padding: 20px;
    }
    
    h1 {
        font-size: 1.8rem;
    }
    
    #modal-container {
        width: 90vw;
        height: 80vh;
    }
    
    .keyboard-key {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
    
    .key-wide {
        width: 90px;
    }
}