/* =========================================================
   町内会オンライン
   共通スタイル
========================================================= */

* {
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
}

body {
    margin: 0;
    background: #f4f6f8;
    color: #333;

    font-family:
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        "Hiragino Kaku Gothic ProN",
        "Yu Gothic",
        "Meiryo",
        sans-serif;

    font-size: 16px;
    line-height: 1.7;
}

a {
    color: inherit;
}


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

header {
    background: #fff;
    border-bottom: 1px solid #ddd;
}

.header-inner {
    width: 100%;
    max-width: 1100px;

    margin: 0 auto;
    padding: 18px 20px;

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

.header-inner h1 {
    margin: 0;

    font-size: 22px;
    line-height: 1.4;
}

.header-link,
.back {
    color: #333;

    text-decoration: none;
    font-weight: 700;
}

.header-link:hover,
.back:hover {
    text-decoration: underline;
}


/* =========================================================
   MAIN
========================================================= */

main {
    width: 100%;
    max-width: 1100px;

    margin: 0 auto;
    padding: 30px 20px 60px;
}

.page-title {
    margin: 0 0 8px;

    font-size: 30px;
    line-height: 1.4;
}

.intro {
    margin: 0 0 30px;

    color: #666;
    line-height: 1.8;
}


/* =========================================================
   PANEL
========================================================= */

.panel {
    margin-bottom: 25px;
    padding: 25px;

    background: #fff;

    border-radius: 14px;

    box-shadow:
        0 2px 10px
        rgba(0, 0, 0, .05);
}

.panel h2,
.panel h3 {
    margin-top: 0;
}


/* =========================================================
   LARGE MENU BUTTONS
========================================================= */

.menu-grid {
    display: grid;

    grid-template-columns:
        repeat(2, minmax(0, 1fr));

    gap: 20px;
}

.menu-card {
    min-height: 190px;

    padding: 28px 24px;

    display: flex;
    flex-direction: column;

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

    background: #fff;
    color: #333;

    text-align: center;
    text-decoration: none;

    border: 2px solid transparent;
    border-radius: 16px;

    box-shadow:
        0 3px 12px
        rgba(0, 0, 0, .07);

    cursor: pointer;

    transition:
        transform .15s ease,
        border-color .15s ease,
        box-shadow .15s ease;
}

.menu-card:hover {
    transform: translateY(-3px);

    border-color: #777;

    box-shadow:
        0 6px 18px
        rgba(0, 0, 0, .11);
}

.menu-card:focus {
    outline: 3px solid #999;
    outline-offset: 3px;
}

.icon {
    margin-bottom: 10px;

    font-size: 48px;
    line-height: 1.2;
}

.menu-title {
    margin-bottom: 8px;

    font-size: 25px;
    font-weight: 700;

    line-height: 1.4;
}

.menu-description {
    color: #666;

    font-size: 16px;
    line-height: 1.7;
}


/* =========================================================
   ADMIN TOP CARDS
========================================================= */

.menu,
.admin-menu {
    display: grid;

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

    gap: 20px;
}

.card {
    min-height: 160px;

    padding: 25px;

    background: #fff;

    border-radius: 14px;

    box-shadow:
        0 3px 12px
        rgba(0, 0, 0, .06);
}

.card h2 {
    margin-top: 0;

    font-size: 21px;
}

.card p {
    margin-bottom: 0;

    color: #666;
}

.card-link {
    display: block;

    color: #333;
    text-decoration: none;

    cursor: pointer;

    transition:
        transform .15s ease,
        box-shadow .15s ease;
}

.card-link:hover {
    transform: translateY(-3px);

    box-shadow:
        0 6px 18px
        rgba(0, 0, 0, .11);
}


/* =========================================================
   FORM
========================================================= */

label {
    display: block;

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

    font-weight: 700;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"],
input[type="number"],
input[type="date"],
input[type="time"],
select,
textarea {
    width: 100%;

    padding: 13px 14px;

    background: #fff;
    color: #333;

    font-size: 16px;

    border: 1px solid #bbb;
    border-radius: 8px;
}

input:focus,
select:focus,
textarea:focus {
    outline: 2px solid #777;
    outline-offset: 1px;
}

textarea {
    min-height: 100px;
    resize: vertical;
}

.help {
    margin-top: 6px;

    color: #777;
    font-size: 14px;
}


/* =========================================================
   BUTTON
========================================================= */

.btn {
    display: inline-block;

    margin-top: 20px;
    padding: 13px 24px;

    border: 0;
    border-radius: 8px;

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

    line-height: 1.5;

    cursor: pointer;

    text-decoration: none;

    text-align: center;
}

.btn-main {
    background: #333;
    color: #fff;
}

.btn-main:hover {
    opacity: .85;
}

.btn-sub {
    background: #eee;
    color: #333;
}

.btn-sub:hover {
    background: #ddd;
}


/* =========================================================
   MESSAGE
========================================================= */

.message,
.error,
.warning {
    margin-bottom: 20px;
    padding: 15px 18px;

    border-radius: 8px;

    line-height: 1.7;
}

.message {
    background: #edf8ef;

    border:
        1px solid #b9dfbf;
}

.error {
    background: #fff0f0;

    border:
        1px solid #e5bcbc;
}

.warning {
    background: #fff8e5;

    border:
        1px solid #ead69b;
}


/* =========================================================
   LIST CARD
========================================================= */

.area-card,
.list-card {
    margin-bottom: 15px;
    padding: 20px;

    background: #fff;

    border: 1px solid #ddd;
    border-radius: 10px;
}

.area-card.inactive,
.list-card.inactive {
    opacity: .55;
}

.area-name,
.list-title {
    font-size: 21px;
    font-weight: 700;
}

.area-code,
.list-sub {
    margin-top: 5px;

    color: #777;
}

.area-description,
.list-description {
    margin-top: 10px;

    line-height: 1.7;
}


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

.status {
    display: inline-block;

    margin-top: 10px;
    padding: 4px 10px;

    background: #eee;

    border-radius: 20px;

    font-size: 13px;
}


/* =========================================================
   ACTIONS
========================================================= */

.actions {
    margin-top: 15px;

    display: flex;
    flex-wrap: wrap;

    gap: 10px;
}

.actions .btn {
    margin-top: 0;
}

.inline-form {
    display: inline-block;
    margin: 0;
}


/* =========================================================
   TABLE
========================================================= */

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

table {
    width: 100%;

    border-collapse: collapse;

    background: #fff;
}

th,
td {
    padding: 12px 14px;

    border-bottom: 1px solid #ddd;

    text-align: left;
    vertical-align: top;
}

th {
    background: #f5f5f5;

    font-weight: 700;
}


/* =========================================================
   WELCOME
========================================================= */

.welcome {
    margin-bottom: 30px;
    padding: 20px;

    background: #fff;

    border-radius: 12px;

    box-shadow:
        0 2px 8px
        rgba(0, 0, 0, .05);
}


/* =========================================================
   LOGIN
========================================================= */

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

    margin: 60px auto;
    padding: 35px;

    background: #fff;

    border-radius: 14px;

    box-shadow:
        0 3px 16px
        rgba(0, 0, 0, .08);
}

.login-box h1 {
    margin: 0 0 10px;

    font-size: 27px;
}

.login-box .sub {
    margin-bottom: 30px;

    color: #666;
}


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

@media (max-width: 700px) {

    body {
        font-size: 16px;
    }

    .header-inner {
        padding: 15px;

        flex-direction: column;
        align-items: flex-start;

        gap: 8px;
    }

    main {
        padding:
            22px 15px
            50px;
    }

    .page-title {
        font-size: 25px;
    }

    .menu-grid {
        grid-template-columns: 1fr;

        gap: 15px;
    }

    .menu-card {
        min-height: 150px;

        padding: 22px 18px;
    }

    .icon {
        font-size: 42px;
    }

    .menu-title {
        font-size: 23px;
    }

    .panel {
        padding: 20px 16px;
    }

    .btn {
        width: 100%;

        padding: 14px 15px;
    }

    .actions {
        display: block;
    }

    .actions .btn {
        margin-top: 8px;
    }

    .inline-form {
        display: block;
        width: 100%;
    }

    .login-box {
        margin: 25px auto;
        padding: 25px 20px;
    }
}