* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    font-family: 'Georgia', serif;
    background: linear-gradient(135deg, #2b4eeb 0%, #7c41b7 100%);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}
.container {
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    padding: 40px;
    max-width: 500px;
    width: 100%;
}
h1 {
    text-align: center;
    color: #2b4eeb;
    font-size: 2.5em;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.1);
}
.subtitle {
    text-align: center;
    color: #666;
    font-size: 0.9em;
    margin-bottom: 30px;
    font-style: italic;
}
.input-group {
    margin-bottom: 20px;
}
label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: bold;
    font-size: 1.1em;
}
#number {
    width: 100%;
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 10px;
    font-size: 1.2em;
    transition: all 0.3s ease;
    font-family: 'Georgia', serif;
}
#number:focus {
    outline: none;
    border-color: #2b4eeb;
    box-shadow: 0 0 10px rgba(102, 126, 234, 0.3);
}
#convert-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #2b4eeb 0%, #7c41b7 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 1.2em;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}
#convert-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(102, 126, 234, 0.4);
}
#convert-btn:active {
    transform: translateY(0);
}
#output {
    margin-top: 30px;
    padding: 25px;
    background: #f8f9fa;
    border-radius: 10px;
    min-height: 80px;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5em;
    font-weight: bold;
    color: #333;
    text-align: center;
    border: 2px solid #e0e0e0;
    transition: all 0.3s ease;
}
#output.result {
    background: linear-gradient(135deg, #2b4eeb 0%, #7c41b7 100%);
    color: white;
    font-size: 2.5em;
    letter-spacing: 3px;
    border-color: #2b4eeb;
}
#output.error {
    background: #fee;
    color: #c33;
    border-color: #fcc;
    font-size: 1.1em;
}
.reference {
    margin-top: 30px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 10px;
    font-size: 0.9em;
}
.reference h2 {
    color: #2b4eeb;
    margin-bottom: 10px;
    text-align: center;
}
.reference-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-top: 15px;
}
.reference-item {
    text-align: center;
    padding: 8px;
    background: white;
    border-radius: 5px;
    border: 1px solid #ddd;
}

.reference-item .roman {
    font-weight: bold;
    color: #2b4eeb;
}