/* add all special styles used for displaying the rules */
/* .rules: used for all elements loading rules (rules at main site, rules ingame, popup with rules extract
   #rules: div with complete rules used at main site
   #rulesPage: ingame rules page display
   #panelRules: ingame rules sidepanel display
   #popup.rules: popup with rules extract only */


/* add special fonts if wanted */

/* add styles for headers h1-h5 if needed*/

/* cover picture only in main rules */
#rules .cover {    width: 60%;    margin-left: 20%;}
#panelRules .cover {    display: none;}

.rules .content ul {list-style-type: none;}

/* flex style for responsive display */
.rules .flex { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5em; }
@media (max-width: 768px) {
    .rules .flex.mobile { flex-direction: column; /* columns below each other */  }
}
#panelRules .flex.mobile { flex-direction: column; }
.rules .flex .column {    flex: 1; }
.rules .flex .column.wide {    flex: 2; }


/* example variable flex structure putting flexboxes half their wide on wide screen full rules
.rules  .flex.appendix .flexbox { flex: 2 2 23%;  padding:0.5em; padding-right: 1em;}
.rules  .flex.appendix .flexbox img { height:5em; float: left; margin-right: 1em; }
@media (max-width: 1024px) {
    .rules .flex.appendix .flexbox { flex: 2 2 48%; }
}
#panelRules .flex.appendix .flexbox { flex: 2 2 48%; }
*/


/* Examples */
.rules .example { font-style: italic; } /* put your example style here */
#panelRules .example { display: none; } /* examples should not be shown in sidebar */


/* Attika: olive headings and ivory paper inside the original terracotta frame. */
@font-face {
    font-family: "Attika Rules";
    src: url("/game-plugins/attika2/1.0.0/fonts/FiraSansCondensed-Regular.ttf") format("truetype");
    font-style: normal;
    font-weight: 400;
    font-display: swap;
}
.at-rules {
    max-width: 1000px;
    margin: 0 auto;
    padding: clamp(12px, 3%, 32px);
    box-sizing: border-box;
    border: 9px solid #ad4a24;
    outline: 2px solid #59593f;
    outline-offset: -13px;
    background: #fffef1;
    color: #414432;
    font: 18px/1.45 "Attika Rules", sans-serif;
    overflow-wrap: break-word;
}
.at-rules * { box-sizing: border-box; }
.at-rules header { text-align: center; }
.at-rules header h1 { margin: 0; font: 48px/1.2 Georgia, serif; letter-spacing: .08em; }
.at-rules header img { display: block; width: min(100%, 460px); margin: 12px auto; }
.at-rules nav { margin: 20px 0 28px; }
.at-rules nav ul { margin: 0; padding: 0; }
.at-rules nav li { margin: 0 0 5px; }
.at-rules a { color: #55562f; text-decoration: underline; }
.at-rules h2, .at-rules h3, .at-rules h4 { font-family: "Attika Rules", sans-serif; line-height: 1.25; color: #454a31; }
.at-rules h2 { margin: 28px 0 14px; padding: 4px 0; font-size: 26px; border-top: 3px double #7b8060; border-bottom: 3px double #7b8060; }
.at-rules h3 { margin: 24px 0 12px; padding-bottom: 3px; font-size: 22px; border-bottom: 2px solid #7b8060; }
.at-rules h4 { margin: 0 0 10px; text-align: center; font-size: 20px; }
.at-rules p { margin: 0 0 14px; }
.at-rules img { max-width: 100%; height: auto; }
.at-rules .flex { gap: 18px; align-items: flex-start; }
.at-rules .column { min-width: 0; }
.at-rules .column.illustration { flex: 0 1 150px; }
.at-rules .chapter > img { display: block; margin: 12px auto; }
.at-rules .chapter a[name] { scroll-margin-top: 12px; }
.at-rules .itemisation { display: grid; grid-template-columns: 3em 1fr; gap: 4px 12px; }
.at-rules .itemcnt { text-align: right; font-weight: bold; }
.at-rules .itemisation .itemcnt { float: none; width: auto; }
.at-rules .itemisation .item { margin-left: 0; }
.at-rules .example { padding: 8px 12px; background: #f3f0d6; }
.at-rules .deviation { padding: 12px; border: 2px solid #975137; background: #fff; }
.at-rules .sidebarOnly { display: none; }
#panelRules .at-rules { padding: 12px; border-width: 4px; outline: none; font-size: 16px; }
#panelRules .at-rules .noSidebar, #panelRules .at-rules .example { display: none; }
#panelRules .at-rules .sidebarOnly { display: block; }
#panelRules .at-rules .flex.mobile { flex-direction: column; }
#panelRules .at-rules .column.illustration { flex-basis: auto; max-width: 120px; align-self: center; }
#panelRules .at-rules h2 { font-size: 23px; }
#panelRules .at-rules h3 { font-size: 20px; }
.at-rules a:focus-visible { outline: 3px solid #a15b27; outline-offset: 2px; }
@media (max-width: 768px) {
    .at-rules .column.illustration { flex-basis: auto; max-width: 150px; align-self: center; }
}
@media print {
    .at-rules { max-width: none; border: 0; outline: none; padding: 0; font-size: 11pt; }
    .at-rules nav { display: none; }
    .at-rules h2, .at-rules h3 { break-after: avoid; }
}
