/* --- FONT DEFINITIONS --- */
/* This rule tells the browser how to load your local font file for handwriting. */
@font-face {
    font-family: 'Run Wild';
    src: url('Run Wild.ttf') format('truetype');
}

/* This rule loads your local font file for the bank stamp. */
@font-face {
    font-family: '1942';
    src: url('1942.ttf') format('truetype');
}


/* --- GENERAL STYLING --- */
body {
    font-family: Arial, sans-serif;
    background-color: #e9e9e9;
    color: #333;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    padding: 20px;
}

h1 {
    color: #d35400; /* An orange-red color for the title */
}

.app-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    max-width: 650px;
    background-color: #fff;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border-radius: 8px;
    padding: 20px;
}


/* --- FORM STYLING --- */
#slipForm {
    display: grid;
    /* Creates a responsive grid that adjusts columns on smaller screens */
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    width: 100%;
    margin-bottom: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

label {
    margin-bottom: 5px;
    font-weight: bold;
    color: #555;
    font-size: 0.9em;
}

input,
select {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 16px;
}

.denomination div {
    display: flex;
    align-items: center;
    gap: 5px;
}

.denomination span {
    font-weight: bold;
}


/* --- CANVAS STYLING --- */
#slipCanvas {
    border: 1px solid #ddd;
    max-width: 100%;
    height: auto;
}


/* --- TOGGLE SWITCH STYLES (for the stamp) --- */
.stamp-toggle {
    align-items: center; /* Vertically aligns the label and switch */
}

.switch {
    position: relative;
    display: inline-block;
    width: 60px;
    height: 34px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 26px;
    width: 26px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
}

input:checked + .slider {
    background-color: #d35400; /* Matches the title color when active */
}

input:checked + .slider:before {
    transform: translateX(26px);
}

.slider.round {
    border-radius: 34px;
}

.slider.round:before {
    border-radius: 50%;
}


/* --- DOWNLOAD BUTTON STYLES --- */
#downloadBtn {
    margin-top: 25px;
    padding: 12px 25px;
    font-size: 18px;
    font-weight: bold;
    color: white;
    background-color: #c0392b; /* A strong red color */
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.2s ease-in-out;
}

#downloadBtn:hover {
    background-color: #a93226; /* A slightly darker red on hover */
}