:root {
    --bg: #FFF9E9;
    --blck: #241F21;
    --wht: #ffffff;
    --lght-yellow: #FFDC7C;
    --lght-blue: #D8E1FF;
    --blue: #3E68FE;
    --green: #00b94c;
    --red: #ff6908;
    --itc: itc-avant-garde-gothic-pro, sans-serif;
    --gtm: GT Maru, 'Courier New', Courier, monospace;
}

@font-face {
    font-family: GT Maru;
    src: url('GTMaruVF.woff2') format('woff2'); 
}

body {
    font-family: var(--gtm);
    background-color: var(--bg);
    color: var(--blck);
    margin: 0;
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

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

/* Header styling */

header {
    text-align: center;
    margin-bottom: 30px;
}

header h1 {
    font-size: 24px;
    margin-bottom: 6px;
    font-family: var(--gtm);
}

header p {
    font-size: 16px;
    font-family: var(--itc);
    margin-bottom: 6px;
}

#profo {
    width: 69px;
    height: 69px;
    border-radius: 69px;
    background-color: var(--blue);
}

/* linkies styling */

.links-container {
    width: 100%;
    max-width: 500px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.link-card {
    display: flex;
    align-items: center;
    gap: 24px;
    border-radius: 12px;
    text-decoration: none;
    color: var(--blck);
    font-weight: bold;
    font-size: 16px;
    transition: 0.3s;
}

.link-card img {
    max-width: 100px;
    max-height: 125px;
    border-radius: 12px;
    padding: -12px !important;
}

.bg-yellow:hover, .bg-blue:hover {
    transform: scale(1.02);
}

.bg-yellow {
    background-color: var(--lght-yellow);
}

.bg-blue {
    background-color: var(--lght-blue);
}

.add {
    background-color: transparent;
    padding: 24px 0px 24px 48px;
    border: #D8E1FF 2px dashed;
    margin-bottom: 24px;
}
.add:hover {
    background-color: var(--lght-blue);
    cursor: pointer;
}

.ltxt, .ctxt {
    flex-grow: 10;
}

.arrow, .pen {
    font-size: 24px;
    transition: 0.3s;
    text-decoration: none;;
    padding-right: 24px;
    color: var(--blck);
    cursor: pointer;
}

.link-card:hover .arrow, .link-card:hover .pen {
    transform: scale(1.2);
}

/* FOOTER styling */

footer {
    text-align: center;
    font-family: var(--gtm);
    font-size: 12px;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 48px;
    padding-top: 48px;
}

footer #socials {
    display: flex;
    flex-direction: row;
    justify-content: center;
    align-items: center;
    gap: 36px;
}

.someicon {
    max-width: 36px;
    max-height: 36px;
}

.someicon:hover {
    filter: invert(32%) sepia(61%) saturate(3784%) hue-rotate(222deg) brightness(103%) contrast(99%);
    transition: 0.3s;
}

footer #fofo {
    width: 100%;
    max-width: 500px;
    height: auto;
}


/* login page */

.login-box {
    margin-top: 48px;
    background: var(--wht);
    padding: 48px;
    border-radius: 12px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 12px;
    max-width: 500px;
}

.btn {
    background: var(--blue);
    color: white;
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 6px;
    font-family: var(--itc);
    font-size: 0.72rem;
    border: none;
    cursor: pointer;
}

.btn:hover {
    background: var(--lght-blue);
    color: var(--blue);
    border-radius: 12px;
    transition: 0.2s;
}

/* admin page */

h2 {
    padding-bottom: 12px;
}

.form-group input[type="text"], .form-group input[type="url"] {
    width: 100%;
    font-family: var(--itc);
    font-size: 0.8rem;
    color: var(--blck);
    background: var(--lght-blue);
    border: 1.5px solid var(--border);
    border-radius: 5px;
    padding: 8px 10px;
    outline: none;
    transition: border-color 0.15s;
}

.form-group label {
    font-family: var(--itc);
    display: block;
    font-size: 0.68rem;
    font-weight: 500;
    color: var(--blck);
    letter-spacing: 0.05em;
    margin-bottom: 5px;
}

.form-group {
    margin-bottom: 14px;
}

/* Modal Overlay Background */
.modal-overlay {
    display: none; /* Hidden by default */
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(36, 31, 33, 0.7); /* Dark semi-transparent overlay */
    z-index: 1000;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(1px);
    -webkit-backdrop-filter: blur(1px);
}

/* Toggles the display */
.modal-overlay.active {
    display: flex;
}

/* Adjust your existing modal box */
#modal {
    background: var(--wht);
    border-radius: 12px;
    padding: 32px 32px;
    width: 100%;
    max-width: 450px;
    position: relative; /* So we can position the close button inside */
    margin-bottom: 0; /* Overrides previous margin */
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

/* Close Button (X) */
.close-btn {
    position: absolute;
    top: 16px;
    right: 20px;
    font-size: 24px;
    cursor: pointer;
    color: var(--blck);
    background: none;
    border: none;
    font-family: var(--gtm);
    line-height: 1;
}

.close-btn:hover {
    color: var(--red);
}

/* Delete Button Styling */
.delete-btn {
    background: var(--red);
}

.delete-btn:hover {
    color: var(--red);
    background: var(--bg);
}

.button-group {
    padding-top: 12px;
}

.drag-handle {
    cursor: grab;
    background-color: var(--lght-yellow);
    border: var(--lght-yellow) dashed 0px;
}

.drag-handle:hover {
    background-color: transparent;
    border: var(--lght-yellow) dashed 2px;
    transform: scale(0.99);
}

/* --- Admin Link Row Layout --- */
.admin-link-row {
    display: flex;
    align-items: center;
    width: 100%;
    gap: 12px;
}

/* Force the yellow card to fill the middle space */
.admin-link-row .link-card {
    flex-grow: 1;
    padding-right: 24px;
    margin: 0;
}

.pen:hover {
    transform: scale(1.2);
}

/* --- Toggle Switch Styling --- */
.toggle-group {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.switch {
    position: relative;
    display: inline-block;
    width: 46px;
    height: 26px;
}

.switch input { 
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--lght-yellow);
    -webkit-transition: .4s;
    transition: .4s;
}

.slider:before {
    position: absolute;
    content: "";
    height: 20px;
    width: 20px;
    left: 3px;
    bottom: 3px;
    background-color: var(--wht);
    -webkit-transition: .4s;
    transition: .4s;
}

input:checked + .slider {
    background-color: var(--green);
}

input:checked + .slider:before {
    transform: translateX(20px);
}

/* Rounded sliders */
.slider.round {
    border-radius: 34px;
}

.slider.round:before {
    border-radius: 50%;
}

.inactive-row .link-card {
    opacity: 0.5;
    filter: blur(1.2px)
}

.inactive-row .link-card:hover {
    filter: blur(0px);
    opacity: 0.75;
}

/* --- Drag and Drop File Input --- */
.drop-zone {
    width: 100%;
    height: 100px;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    font-family: var(--itc);
    font-size: 0.8rem;
    color: var(--blue);
    background-color: transparent;
    border: 2px dashed var(--blue);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
}

.drop-zone:hover, .drop-zone.dragover {
    background-color: var(--lght-blue);
    transform: scale(0.98);
}

.drop-zone__input {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    opacity: 0; /* Hides the ugly native button but keeps it clickable */
    cursor: pointer;
}

.drop-zone__prompt {
    pointer-events: none; /* Prevents the text from blocking the drag action */
}

.drop-zone.error {
    border-color: var(--red);
    background-color: var(--bg);
    color: var(--red);
}