/* =========================
   LF TAGS - MAIN STYLESHEET
   ========================= */

/* Reset */

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    background: #f5f7fb;
    color: #1f2937;
    line-height: 1.6;
}

/* =========================
   HEADER
   ========================= */

header {
    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
    padding: 16px 5%;

    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo a {
    font-size: 24px;
    font-weight: 700;
    text-decoration: none;
    color: #2563eb;
}

nav {
    display: flex;
    align-items: center;
    gap: 20px;
}

nav a {
    color: #374151;
    text-decoration: none;
    font-weight: 500;
}

nav a:hover {
    color: #2563eb;
}

/* =========================
   BUTTONS
   ========================= */

.button,
button {
    display: inline-block;

    background: #2563eb;
    color: white;

    padding: 12px 20px;

    border: none;
    border-radius: 8px;

    text-decoration: none;

    font-size: 16px;
    font-weight: 600;

    cursor: pointer;

    transition: 0.2s;
}

.button:hover,
button:hover {
    background: #1d4ed8;
    transform: translateY(-1px);
}

/* =========================
   HOMEPAGE
   ========================= */

.hero {
    max-width: 800px;
    margin: 100px auto;

    text-align: center;
    padding: 20px;
}

.hero h1 {
    font-size: 48px;
    margin-bottom: 15px;
}

.hero p {
    font-size: 20px;
    color: #6b7280;

    margin-bottom: 30px;
}

/* =========================
   HOW IT WORKS
   ========================= */

.how-it-works {
    max-width: 1100px;
    margin: auto;

    padding: 50px 20px;
}

.how-it-works h2 {
    text-align: center;
    font-size: 32px;

    margin-bottom: 40px;
}

.steps {
    display: grid;

    grid-template-columns:
        repeat(auto-fit, minmax(220px, 1fr));

    gap: 25px;
}

.step {
    background: white;

    padding: 30px;

    border-radius: 12px;

    box-shadow:
        0 4px 12px rgba(0,0,0,0.05);

    text-align: center;
}

.step h3 {
    margin-top: 0;
}

/* =========================
   LOGIN / ACCOUNT PAGES
   ========================= */

.login-container {
    min-height: 100vh;

    display: flex;

    justify-content: center;
    align-items: center;

    padding: 20px;
}

.login-box {
    width: 100%;
    max-width: 450px;

    background: white;

    padding: 40px;

    border-radius: 16px;

    box-shadow:
        0 10px 30px rgba(0,0,0,0.08);
}

.login-box h1 {
    margin-top: 0;
}

.login-box label {
    display: block;

    margin-top: 18px;
    margin-bottom: 6px;

    font-weight: 600;
}

.login-box input {
    width: 100%;

    padding: 12px;

    border: 1px solid #d1d5db;

    border-radius: 8px;

    font-size: 16px;
}

.login-box input:focus {
    outline: none;

    border-color: #2563eb;

    box-shadow:
        0 0 0 3px rgba(37,99,235,0.1);
}

.login-box button {
    width: 100%;

    margin-top: 25px;
}

/* =========================
   ERRORS / SUCCESS
   ========================= */

.error {
    background: #fee2e2;
    color: #991b1b;

    padding: 12px;

    border-radius: 8px;

    margin-bottom: 20px;
}

.success {
    background: #dcfce7;
    color: #166534;

    padding: 12px;

    border-radius: 8px;

    margin-bottom: 20px;
}

/* =========================
   DASHBOARD
   ========================= */

.dashboard {
    max-width: 1200px;

    margin: auto;

    padding: 40px 20px;
}

.dashboard-header {
    display: flex;

    justify-content: space-between;

    align-items: center;

    gap: 20px;

    margin-bottom: 40px;
}

.dashboard-header h1 {
    margin-bottom: 5px;
}

/* =========================
   STATS
   ========================= */

.stats {
    display: grid;

    grid-template-columns:
        repeat(auto-fit, minmax(200px, 1fr));

    gap: 20px;

    margin-bottom: 40px;
}

.stat-card {
    background: white;

    padding: 30px;

    border-radius: 14px;

    box-shadow:
        0 4px 12px rgba(0,0,0,0.05);
}

.stat-number {
    display: block;

    font-size: 36px;

    font-weight: 700;

    color: #2563eb;
}

.stat-label {
    color: #6b7280;
}

/* =========================
   TAGS
   ========================= */

.tags-section {
    margin-top: 30px;
}

.section-header {
    margin-bottom: 20px;
}

.tag-grid {
    display: grid;

    grid-template-columns:
        repeat(auto-fit, minmax(280px, 1fr));

    gap: 20px;
}

.tag-card {
    background: white;

    padding: 25px;

    border-radius: 14px;

    box-shadow:
        0 4px 12px rgba(0,0,0,0.05);
}

.tag-card-header {
    display: flex;

    justify-content: space-between;

    align-items: center;

    gap: 10px;
}

.tag-card-header h3 {
    margin: 0;
}

/* =========================
   STATUS BADGES
   ========================= */

.status {
    padding: 5px 10px;

    border-radius: 20px;

    font-size: 13px;

    font-weight: 600;
}

.status-active {
    background: #dcfce7;
    color: #166534;
}

.status-lost {
    background: #fee2e2;
    color: #991b1b;
}

.status-disabled {
    background: #e5e7eb;
    color: #374151;
}

/* =========================
   TAG CODE
   ========================= */

.tag-code {
    margin-top: 20px;

    padding: 12px;

    background: #f3f4f6;

    border-radius: 8px;
}

.tag-code span {
    display: block;

    font-size: 12px;

    color: #6b7280;
}

.tag-code strong {
    font-size: 18px;

    letter-spacing: 1px;
}

/* =========================
   EMPTY STATE
   ========================= */

.empty-state {
    background: white;

    padding: 50px;

    text-align: center;

    border-radius: 14px;

    box-shadow:
        0 4px 12px rgba(0,0,0,0.05);
}

/* =========================
   FOOTER
   ========================= */

footer {
    text-align: center;

    padding: 30px;

    color: #6b7280;
}

/* =========================
   MOBILE
   ========================= */

@media (max-width: 700px) {

    header {
        flex-direction: column;

        gap: 15px;
    }

    .hero {
        margin: 60px auto;
    }

    .hero h1 {
        font-size: 36px;
    }

    .dashboard-header {
        flex-direction: column;

        align-items: flex-start;
    }

    nav {
        flex-wrap: wrap;

        justify-content: center;
    }

}
.login-box textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 16px;
    font-family: inherit;
    resize: vertical;
}

.login-box textarea:focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 3px rgba(37,99,235,0.1);
}
/* =========================
   TAG DETAILS
   ========================= */

.tag-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 25px;
}

.tag-info-card,
.qr-card {
    background: white;
    padding: 30px;
    border-radius: 14px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
}

.detail-row {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    padding: 15px 0;
    border-bottom: 1px solid #e5e7eb;
}

.detail-row span {
    color: #6b7280;
}

.description {
    margin-top: 25px;
}

.qr-placeholder {
    margin: 30px 0;
    padding: 60px 20px;
    text-align: center;
    background: #f3f4f6;
    border-radius: 12px;
    font-size: 20px;
}

.public-link input {
    width: 100%;
    margin-top: 10px;
    padding: 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
}
.qr-code {
    margin: 30px 0;
    text-align: center;
}

.qr-code img {
    width: 300px;
    max-width: 100%;
    height: auto;
    background: white;
    padding: 15px;
    border-radius: 12px;
}
/* =========================
   FOUND PAGE
   ========================= */

.found-container {
    min-height: calc(100vh - 70px);

    display: flex;
    justify-content: center;
    align-items: center;

    padding: 30px 20px;
}

.found-box {
    width: 100%;
    max-width: 600px;

    background: white;

    padding: 40px;

    border-radius: 16px;

    box-shadow:
        0 10px 30px rgba(0,0,0,0.08);

    text-align: center;
}

.found-icon {
    font-size: 60px;
    margin-bottom: 10px;
}

.found-box h1 {
    margin-top: 0;
}

.found-intro {
    color: #6b7280;
    font-size: 17px;
}

.found-item {
    margin: 30px 0;
    padding: 20px;

    background: #f3f4f6;
    border-radius: 12px;
}

.found-item span {
    display: block;
    color: #6b7280;
    font-size: 14px;
}

.found-item strong {
    display: block;
    font-size: 24px;
    margin-top: 5px;
}

.found-description {
    margin-bottom: 30px;
    padding: 15px;

    color: #4b5563;
}

.found-box h2 {
    margin-top: 30px;
}

.found-box form {
    text-align: left;
    margin-top: 20px;
}

.found-box label {
    display: block;
    margin-top: 18px;
    margin-bottom: 6px;
    font-weight: 600;
}

.found-box input,
.found-box textarea {
    width: 100%;
    padding: 12px;

    border: 1px solid #d1d5db;
    border-radius: 8px;

    font-size: 16px;
    font-family: inherit;
}

.found-box textarea {
    resize: vertical;
}

.found-box input:focus,
.found-box textarea:focus {
    outline: none;

    border-color: #2563eb;

    box-shadow:
        0 0 0 3px rgba(37,99,235,0.1);
}

.found-box button {
    width: 100%;
    margin-top: 25px;
}

.found-footer {
    margin-top: 35px;
    color: #9ca3af;
    font-size: 14px;
}
/* =========================
   MESSAGES
   ========================= */

.messages-list {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.message-card {
    background: white;
    padding: 25px;
    border-radius: 14px;

    box-shadow:
        0 4px 12px rgba(0,0,0,0.05);

    border-left: 4px solid transparent;
}

.message-card.unread {
    border-left-color: #2563eb;
}

.message-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;

    border-bottom: 1px solid #e5e7eb;

    padding-bottom: 15px;
    margin-bottom: 15px;
}

.message-header h2 {
    margin: 0;
}

.message-tag {
    margin: 5px 0 0;
    color: #6b7280;
}

.unread-badge {
    background: #2563eb;
    color: white;

    padding: 5px 10px;
    border-radius: 20px;

    font-size: 13px;
    font-weight: 600;
}

.message-content {
    font-size: 16px;
    margin-bottom: 20px;
}

.finder-info {
    padding: 8px 0;
    color: #374151;
}

.message-footer {
    margin-top: 20px;
    padding-top: 15px;

    border-top: 1px solid #e5e7eb;

    display: flex;
    justify-content: space-between;
    gap: 20px;

    color: #6b7280;
    font-size: 14px;
}

.message-footer a {
    color: #2563eb;
    text-decoration: none;
    font-weight: 600;
}

.message-footer a:hover {
    text-decoration: underline;
}

@media (max-width: 600px) {

    .message-header,
    .message-footer {
        flex-direction: column;
        gap: 10px;
    }

}
/* MESSAGE DETAIL */

.message-detail {
    max-width: 800px;
}

.message-full {
    white-space: normal;
    line-height: 1.7;
    font-size: 17px;
}
.tag-actions {
    margin-top: 25px;
}

.tag-actions form {
    margin: 0;
}

.button-lost {
    background: #dc2626;
}

.button-lost:hover {
    background: #b91c1c;
}
/* LOST ITEM ALERT */

.lost-alert {
    background: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;

    padding: 18px;
    border-radius: 12px;

    margin: 20px 0;
}

.lost-alert p {
    margin: 8px 0 0;
}
/* DELETE TAG */

.action-divider {
    border: none;
    border-top: 1px solid #e5e7eb;
    margin: 25px 0;
}

.button-delete {
    background: #991b1b;
}

.button-delete:hover {
    background: #7f1d1d;
}
/* TAG ACTIONS */

.tag-actions {
    margin-top: 30px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tag-actions form {
    margin: 0;
}

.tag-actions .button {
    width: 100%;
    box-sizing: border-box;
    text-align: center;
}


/* DIVIDER */

.action-divider {
    width: 100%;
    border: none;
    border-top: 1px solid #e5e7eb;
    margin: 10px 0;
}


/* LOST BUTTON */

.button-lost {
    background: #dc2626;
}

.button-lost:hover {
    background: #b91c1c;
}


/* DELETE BUTTON */

.button-delete {
    background: #991b1b;
}

.button-delete:hover {
    background: #7f1d1d;
}
/* EDIT TAG PAGE */

.form-card {
    max-width: 700px;
    background: #ffffff;
    padding: 30px;
    border-radius: 12px;
    box-sizing: border-box;
}

.form-card form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.form-card label {
    font-weight: 600;
    margin-top: 8px;
}

.form-card input,
.form-card textarea {
    width: 100%;
    box-sizing: border-box;

    padding: 12px;

    border: 1px solid #d1d5db;
    border-radius: 8px;

    font-size: 16px;
    font-family: inherit;
}

.form-card textarea {
    resize: vertical;
    min-height: 140px;
}

.form-card input:focus,
.form-card textarea:focus {
    outline: none;
    border-color: #2563eb;
}
/* PRINT TAG PAGE */

.print-page {
    background: #f3f4f6;
    padding: 30px;
}

.print-controls {
    max-width: 600px;
    margin: 0 auto 30px;

    display: flex;
    justify-content: space-between;
    gap: 15px;
}

.print-label {
    max-width: 500px;
    margin: auto;

    background: white;

    padding: 40px;

    text-align: center;

    border-radius: 12px;

    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

.print-logo h1 {
    margin-bottom: 5px;
}

.print-logo p {
    margin-top: 0;
    font-size: 18px;
}

.print-qr img {
    width: 100%;
    max-width: 400px;
    height: auto;

    margin: 20px auto;
}

.print-item {
    font-size: 24px;
    font-weight: bold;

    margin-top: 15px;
}

.print-tag-code {
    font-size: 16px;
    margin-top: 8px;

    font-family: monospace;
}

.print-instructions {
    margin-top: 25px;
    line-height: 1.5;
}


/* PRINTING */

@media print {

    .print-controls {
        display: none;
    }

    .print-page {
        background: white;
        padding: 0;
    }

    .print-label {
        box-shadow: none;
        border-radius: 0;
        padding: 20px;
    }

}


/* LABEL SIZES */

.label-large {
    max-width: 500px;
}

.label-medium {
    max-width: 350px;
}

.label-small {
    max-width: 220px;
}


/* SMALL LABEL ADJUSTMENTS */

.label-small .print-logo h1 {
    font-size: 22px;
}

.label-small .print-logo p {
    font-size: 14px;
}

.label-small .print-item {
    font-size: 16px;
}

.label-small .print-instructions {
    font-size: 12px;
}

.label-small .print-tag-code {
    font-size: 12px;
}
/* ADMIN DASHBOARD */

.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.admin-stat-card {
    background: white;
    padding: 25px;
    border-radius: 12px;
    text-align: center;
}

.admin-stat-card span {
    font-size: 32px;
}

.admin-stat-card h2 {
    font-size: 32px;
    margin: 10px 0 5px;
}

.admin-stat-card p {
    margin: 0;
}


.admin-actions {
    margin-top: 30px;
}

.admin-action-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
}

.admin-action-card {
    display: block;
    background: white;
    padding: 25px;
    border-radius: 12px;
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s ease;
}

.admin-action-card:hover {
    transform: translateY(-3px);
}

.admin-action-card span {
    font-size: 32px;
}

.admin-action-card h3 {
    margin-bottom: 8px;
}

.admin-action-card p {
    margin: 0;
}
/* ADMIN TABLES */

.admin-table-card {
    background: white;
    padding: 25px;
    border-radius: 12px;
}

.table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th,
.admin-table td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid #e5e7eb;
}

.admin-table th {
    font-weight: 600;
}

.admin-table tbody tr:hover {
    background: #f9fafb;
}
.dashboard-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.admin-button {
    background: #6b21a8;
}

.admin-button:hover {
    background: #581c87;
}
/* ADMIN CREATE USER */

.admin-user-form {
    max-width: 600px;
}

.admin-user-form input {
    width: 100%;
    box-sizing: border-box;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 20px 0;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: auto;
}