* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* BODY & BACKGROUND */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-image: url('/bps1.jpg');
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    position: relative;
    overflow-x: hidden;
}

/* OVERLAY GELAP */
body::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    background: rgba(0, 40, 85, 0.7);
    pointer-events: none;
    z-index: 0;
}

/* DECORATIVE CORNER ELEMENTS */
.corner-decoration-tl,
.corner-decoration-br {
    position: fixed;
    width: 200px;
    height: 200px;
    pointer-events: none;
    z-index: 0;
}

.corner-decoration-tl {
    top: -50px;
    left: -50px;
    background: radial-gradient(circle at top left, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: pulseCorner 8s ease-in-out infinite;
}

.corner-decoration-br {
    bottom: -50px;
    right: -50px;
    background: radial-gradient(circle at bottom right, rgba(255, 255, 255, 0.08) 0%, transparent 70%);
    animation: pulseCorner 8s ease-in-out infinite 4s;
}

/* ANIMATED PARTICLES */
.particles {
    position: fixed;
    width: 100%;
    height: 100%;
    overflow: hidden;
    pointer-events: none;
    z-index: 0;
}

.particle {
    position: absolute;
    width: 3px;
    height: 3px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 50%;
    animation: particle-animation linear infinite;
}

/* CONTAINER */
.container {
    background: #ffffff;
    padding: 40px;
    border-radius: 24px;
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.3),
        0 0 0 1px rgba(255, 255, 255, 0.1);
    width: 100%;
    max-width: 520px;
    position: relative;
    z-index: 1;
    animation: none;
    border: 1px solid rgba(0, 82, 163, 0.1);
}

/* HEADER */
.header {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 30px;
    gap: 16px;
    animation: none;
}

.logo-container {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: white;
    border-radius: 50%;
    padding: 5px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.logo-container::before {
    content: '';
    position: absolute;
    inset: -3px;
    background: transparent;
    border-radius: 50%;
    opacity: 0;
    transition: opacity 0.3s;
    z-index: -1;
}

.logo-container:hover::before {
    opacity: 0;
}

.logo {
    width: 100%;
    height: 100%;
    object-fit: contain;
    filter: none;
    background: transparent;
}

.header-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

h1 {
    color: #666;
    margin: 0;
    font-size: 32px;
    font-weight: 700;
    letter-spacing: -0.5px;
    background: linear-gradient(135deg, #000000 0%, #000000 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.subtitle {
    color: #0052A3;
    font-size: 13px;
    font-weight: 500;
    letter-spacing: 0.3px;
}

/* DIVIDER */
.divider {
    height: 3px;
    background: linear-gradient(90deg, transparent, #0052A3, transparent);
    margin: 24px 0;
    border-radius: 2px;
}

/* FORM GROUPS */
.form-group {
    margin-bottom: 24px;
    animation: fadeInUp 0.6s ease-out backwards;
}

.form-group:nth-child(1) {
    animation-delay: 0.3s;
}

.form-group:nth-child(2) {
    animation-delay: 0.4s;
}

.form-group:nth-child(3) {
    animation-delay: 0.5s;
}

.form-group:nth-child(4) {
    animation-delay: 0.6s;
}

.form-group:nth-child(5) {
    animation-delay: 0.7s;
}

/* FORM LABELS */
label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.2px;
}

/* FORM INPUTS */
input,
textarea {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    font-size: 14px;
    transition: all 0.3s ease;
    font-family: inherit;
    background: #ffffff;
}

input:focus,
textarea:focus {
    outline: none;
    border-color: #0052A3;
    box-shadow: 0 0 0 4px rgba(0, 82, 163, 0.1);
    transform: translateY(-2px);
}

input.error,
textarea.error {
    border-color: #e74c3c;
    animation: shake 0.5s;
}

textarea {
    resize: vertical;
    min-height: 120px;
    font-family: 'Courier New', monospace;
    line-height: 1.6;
}

/* ERROR MESSAGES */
.error-message {
    color: #e74c3c;
    font-size: 12px;
    margin-top: 6px;
    display: none;
    font-weight: 500;
}

.error-message.show {
    display: block;
    animation: slideInFromLeft 0.3s ease-out;
}

/* HELPER TEXT */
.helper-text {
    font-size: 12px;
    color: #666;
    margin-top: 6px;
    font-style: italic;
}

/* SUBMIT BUTTON */
.btn {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #0052A3 0%, #003D7A 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 8px 16px rgba(0, 82, 163, 0.3);
    animation: fadeInUp 0.6s ease-out 0.8s backwards;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 24px rgba(0, 82, 163, 0.4);
}

.btn:active {
    transform: translateY(-1px);
}

.btn:disabled {
    background: linear-gradient(135deg, #ccc 0%, #999 100%);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* MESSAGE BOX */
.message {
    padding: 16px;
    border-radius: 12px;
    margin-bottom: 24px;
    display: none;
    font-size: 14px;
    font-weight: 500;
    animation: slideInFromLeft 0.5s ease-out;
}

.message.success {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    color: #155724;
    border: 2px solid #28a745;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.2);
    display: block;
}

.message.error {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    color: #721c24;
    border: 2px solid #dc3545;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.2);
    display: block;
}

/* REQUIRED INDICATOR */
.required {
    color: #e74c3c;
}

/* EXAMPLE BOX */
.example-box {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 12px;
    border-radius: 8px;
    margin-top: 8px;
    font-size: 12px;
    color: #495057;
    border-left: 4px solid #0052A3;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.example-box strong {
    display: block;
    margin-bottom: 6px;
    color: #0052A3;
    font-weight: 600;
}

/* FOOTER */
.footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 2px solid #e0e0e0;
    content-visibility: auto;
    animation: fadeInUp 0.6s ease-out 0.9s backwards;
}

.footer-text {
    font-size: 12px;
    color: #666;
    font-weight: 500;
}

.footer-text strong {
    color: #0052A3;
    font-weight: 700;
}

/* MOBILE DEVICES (≤ 600px) */
@media (max-width: 600px) {

    /* BODY & BACKGROUND */
    body {
        padding: 15px;
        /* Fix iOS bug dengan fixed background */
        background-attachment: scroll;
        background-size: cover;
        background-position: center;
    }

    /* Overlay lebih gelap */
    body::before {
        background: rgba(0, 40, 85, 0.8);
    }

    /* CONTAINER */
    .container {
        padding: 25px 20px;
        border-radius: 20px;
        max-width: 100%;
    }

    /* HEADER */
    .header {
        gap: 12px;
        margin-bottom: 25px;
    }

    .logo-container {
        width: 50px;
        height: 50px;
    }

    h1 {
        font-size: 24px;
        letter-spacing: -0.3px;
    }

    .subtitle {
        font-size: 12px;
    }

    /* DIVIDER */
    .divider {
        margin: 20px 0;
    }

    /* FORM ELEMENTS */
    .form-group {
        margin-bottom: 20px;
    }

    label {
        font-size: 13px;
        margin-bottom: 6px;
    }

    input,
    textarea {
        padding: 12px 14px;
        font-size: 16px;
        border-radius: 10px;
    }

    textarea {
        min-height: 100px;
    }

    /* ERROR MESSAGES */
    .error-message {
        font-size: 11px;
        margin-top: 5px;
    }

    /* BUTTON */
    .btn {
        padding: 14px;
        font-size: 15px;
        border-radius: 10px;
        min-height: 48px;
    }

    /* MESSAGE BOX */
    .message {
        padding: 14px;
        font-size: 13px;
        margin-bottom: 20px;
    }

    /* FOOTER */
    .footer {
        margin-top: 20px;
        padding-top: 15px;
    }

    .footer-text {
        font-size: 11px;
    }

    /* DECORATIVE ELEMENTS */
    .corner-decoration-tl,
    .corner-decoration-br {
        width: 150px;
        height: 150px;
        opacity: 0.5;
    }

    /* PARTICLES */
    .particle {
        opacity: 0.3;
    }
}

/* SMALL SCREENS (≤ 400px) */
@media (max-width: 400px) {
    body {
        padding: 10px;
    }

    .container {
        padding: 20px 15px;
    }

    .header {
        margin-bottom: 20px;
        flex-direction: column;
        text-align: center;
    }

    .logo-container {
        width: 45px;
        height: 45px;
    }

    h1 {
        font-size: 22px;
    }

    .subtitle {
        font-size: 11px;
        text-align: center;
    }

    .divider {
        margin: 16px 0;
    }

    .form-group {
        margin-bottom: 18px;
    }

    input,
    textarea {
        padding: 10px 12px;
    }

    .btn {
        padding: 12px;
        min-height: 44px;
    }

    .message {
        padding: 12px;
        font-size: 12px;
    }

    .footer {
        margin-top: 18px;
        padding-top: 12px;
    }

    .footer-text {
        font-size: 10px;
    }

    .corner-decoration-tl,
    .corner-decoration-br {
        display: none;
    }
}

/* LANDSCAPE MODE */
@media (max-width: 900px) and (orientation: landscape) {
    body {
        padding: 10px;
        align-items: flex-start;
        padding-top: 20px;
    }

    .container {
        max-width: 600px;
        padding: 20px 25px;
        margin: 20px auto;
    }

    .header {
        margin-bottom: 15px;
    }

    .form-group {
        margin-bottom: 15px;
    }

    .divider {
        margin: 15px 0;
    }

    textarea {
        min-height: 80px;
    }

    .footer {
        margin-top: 15px;
        padding-top: 12px;
    }
}

/* TABLET (601px - 900px) */
@media (min-width: 601px) and (max-width: 900px) {
    body {
        padding: 25px;
    }

    .container {
        max-width: 500px;
        padding: 35px 30px;
    }

    h1 {
        font-size: 28px;
    }

    .subtitle {
        font-size: 12.5px;
    }

    .logo-container {
        width: 55px;
        height: 55px;
    }

    input,
    textarea {
        font-size: 15px;
    }

    .btn {
        font-size: 15px;
    }
}

/* LARGE SCREENS (> 1200px) */
@media (min-width: 1200px) {
    .container {
        max-width: 550px;
        padding: 45px;
    }

    h1 {
        font-size: 34px;
    }

    .subtitle {
        font-size: 14px;
    }
}