@import url('https://fonts.googleapis.com/css2?family=Roboto+Mono:wght@300;400;500;700&display=swap');

*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    height: 100%;
}

body {
    min-height: 100vh;
    background: #0b0b0b;
    color: #1e1e1e;
    font-family: 'Roboto Mono', monospace;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;

    background-image:
        radial-gradient(circle at 15% 85%, rgba(50,35,20,0.2) 0%, transparent 50%),
        radial-gradient(circle at 85% 15%, rgba(60,45,25,0.15) 0%, transparent 50%),
        repeating-linear-gradient(45deg, transparent, transparent 40px, rgba(30,30,30,0.04) 40px, rgba(30,30,30,0.04) 80px);
}

form {
    background: #fdfcf7;
    padding: 60px 70px;
    max-width: 460px;
    width: 100%;
    border: 1px solid #8c7452;
    border-top: 3px solid #b8a685;
    position: relative;
    box-shadow: 0 20px 50px rgba(0,0,0,0.7);
    animation: breathe 14s infinite ease-in-out;
}

@keyframes breathe {
    0%, 100% { box-shadow: 0 20px 50px rgba(0,0,0,0.7); }
    50%      { box-shadow: 0 25px 70px rgba(0,0,0,0.9); }
}

form::before,
form::after {
    content: '';
    position: absolute;
    left: 25px; right: 25px;
    height: 1px;
    background: linear-gradient(90deg, transparent, #b8a685, transparent);
    opacity: 0.7;
}
form::before { top: 0; }
form::after  { bottom: 0; }

form > div:last-child::after {
    content: '◆';
    display: block;
    text-align: center;
    margin-top: 45px;
    font-size: 1.3rem;
    color: #b8a685;
    opacity: 0.5;
    animation: diamond 9s infinite ease-in-out;
}

@keyframes diamond {
    0%, 100% { opacity: 0.4; transform: scale(1)   rotate(0deg); }
    50%      { opacity: 0.8; transform: scale(1.25) rotate(180deg); }
}

h1 {
    text-align: center;
    margin-bottom: 45px;
    font-size: 1.75rem;
    font-weight: 500;
    letter-spacing: 9px;
    text-transform: uppercase;
    color: #1e1e1e;
    opacity: 0.95;
}

form > div {
    margin-bottom: 38px;
    position: relative;
}

label {
    display: block;
    margin-bottom: 10px;
    font-size: 0.8rem;
    letter-spacing: 3px;
    text-transform: uppercase;
    color: #5c4935;
    font-weight: 500;
    transition: color 0.4s ease;
}

input {
    width: 100%;
    padding: 14px 0 12px;
    background: transparent;
    border: none;
    border-bottom: 1.5px solid #8c7452;
    color: #1e1e1e;
    font-family: 'Roboto Mono', monospace;
    font-size: 1.05rem;
    transition: all 0.45s ease;
}

input:focus {
    outline: none;
    border-bottom: 2px solid #1e1e1e;
    background: rgba(140,116,82,0.06);
    padding-left: 10px;
}

input:focus + label,
input:valid + label {
    color: #8c7452;
}

button {
    width: 100%;
    padding: 18px;
    margin-top: 15px;
    background: transparent;
    border: 2px solid #8c7452;
    color: #1e1e1e;
    font-family: 'Roboto Mono', monospace;
    font-weight: 700;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 5px;
    cursor: pointer;
    transition: all 0.6s ease;
    position: relative;
    overflow: hidden;
}

button::before {
    content: '';
    position: absolute;
    top: 0; left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
    transition: left 0.7s;
}

button:hover {
    background: #8c7452;
    color: #fdfcf7;
    letter-spacing: 8px;
    box-shadow: 0 10px 30px rgba(140,116,82,0.4);
}

button:hover::before {
    left: 100%;
}

@media (max-width: 540px) {
    form {
        padding: 50px 40px;
    }
    h1 {
        font-size: 1.5rem;
        letter-spacing: 6px;
    }
}